WINEXIST

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.

Checks if the specified window exists.

Syntax

WINEXIST (title)

where title is a text string or a string with wildcard (?, *). that can be

plain text specifies all or the first part of the title bar of the application window whose existence is to be checked for.
text that contains '*' (ie., 0 or more characters ) and/or '?' (ie., any character), to perform a wildcard search.
Note: Matching of the title is case insensitive.

Returns

One of the following Boolean values:

Value

Description

TRUE

The window exists.

FALSE

The window does not exist.

Example

TIBCO iProcess Modeler:

In a script:

IF WINEXIST ("Microsoft Excel")
WINACTIVATE ("Microsoft Excel")
ELSE
WINRUN ("C:\EXCEL\EXCEL", 1)
ENDIF

TIBCO Business Studio:

if(IPEEnvironmentUtil.WINEXIST("Microsoft Excel"))  {
IPEEnvironmentUtil.WINACTIVATE("Microsoft Excel");
} else {
IPEExternalUtil.WINRUN("C:\\EXCEL\\EXCEL", 1);
}