WINACTION

Usage

TIBCO iProcess Workspace (Windows)

Warning: (iProcess only) This expression is not available to the TIBCO iProcess Script Server Plug-in. Therefore, even though you can successfully enter the expression in your iProcess Script plug-in definition, it will not be processed by the iProcess Engine. It will return SW_NA.

Perform miscellaneous actions on a window.

Syntax

WINACTION (handle, action, x, y)

where:

handle is the numeric value, returned by the GETHANDLE function, indicating the window on which the action is to be performed.
action is a number indicating the action to be performed on the window:

Value

Action

0

close window (supersedes WINCLOSE function)

1

activate window (supersedes WINACTIVATE function)

2

move window to coordinates x, y (supersedes WINMOVE function)

3

re-size window to width x, height y (supersedes WINSIZE function)

4

minimize window (supersedes WINMINIMIZE function)

5

maximize window (supersedes WINMAXIMIZE function)

6

restore window (supersedes WINRESTORE function)

x, y are numeric values depend on action; ignored if irrelevant.

Returns

One of the following numeric values:

Value

Description

0

Success

1

Failure

Example

TIBCO iProcess Modeler:

In a script:

   MYNUMFLD := WINFIND ("Microsoft Excel", 3)
   IF MYNUMFLD >= 0
   ; restore the window
   WINACTION (MYNUMFLD, 6, 0, 0)
   ; activate the window
   WINACTION (MYNUMFLD, 1, 0, 0)
   ; re-size the window
   WINACTION (MYNUMFLD, 3, 300, 200)
   ENDIF

TIBCO Business Studio:

The following closes the window:

MYNUMFLD=IPEEnvironmentUtil.WINFIND("Microsoft Excel",3);
if(MYNUMFLD >= 0) {
IPEEnvironmentUtil.WINACTION(MYNUMFLD,0);
}