|
IF ActionNOTE: This feature is only available in the Professional version of AutoMate |
Description
|
|
|
Parameters
NOTE: The IF Action dialog is laid out with three input areas side by side along the middle of the window. The first input box is referred to as the “first parameter”, box in the middle is the “IF type”, and the last box on the far right in the “second parameter”. The remaining two parameters towards the bottom the dialog box, the Then and Else parameters, are used to tell AutoMate™ what to do when the IF statement you create is true (the then parameter is executed) and when it is false (the else parameter).
First Parameter
This is the first parameter you supply to your IF Action. This can either be straight text (as in a string literal), a variable, or an inline expression. What you put here will ultimately depend on what you select for your IF Type.IF type
This is where you specify what kinds of conditional testing you wish to do. Consult the chart below for a list of what each IF type does, and what each parameter does as a consequence of your choice.Second Parameter
The is the second parameter of the IF Action. This can either be straight text (as in a string literal), a variable, or an inline expression. This parameter has different meanings depending on what IF Type you select. For some IF Types, the second parameter is not even available. Consult the list below (IF Type Descriptions) for a list of all the supported IF Types and what their parameters do.Then
This is where you select what AutoMate™ should do when the IF Action you specify evaluates to true (i.e. the expression you build is correct):Continue the current task
The step returns okay, and the task continues to the next stepStop the current task
The step returns stop, and the task does not continue to the next step, but rather exits gracefully at this step
Start another task concurrently
Allows you to specify another task to start. The selected task starts, and the current task stops.Start another task consecutively
The step returns stop, and the task does not continue to the next step, but rather exits gracefully at this step
Else
This is where you select what AutoMate™ should do when the IF Action you specify evaluates to false (i.e. the expression you build is incorrect):Continue the current task The step returns okay, and the task continues to the next step
Stop the current task The step returns stop, and the task does not continue to the next step, but rather exits gracefully at this step
Start another task Allows you to specify another task to start. The selected task starts, and the current task stops.
IF Type Descriptions
These are the available IF Types, and a description of each:Equals
Tests whether parameter 1 is exactly the same as parameter 2.Does not equal
Tests whether parameter 1 is not exactly the same as parameter 2.Greater than
Tests whether parameter 1 is greater than parameter 2. If these parameters can be converted to numbers, AutoMate™ will do so before comparison. Otherwise, an ANSI text comparison will be done instead.Less than
Tests whether parameter 1 is less than parameter 2. If these parameters can be converted to numbers, AutoMate™ will do so before comparison. Otherwise, an ANSI text comparison will be done instead.Is longer than
Tests whether the length of parameter 1 is greater than the length of parameter 2.Is shorter than
Tests whether the length of parameter 1 is shorter than the length of parameter 2.Is same length as
Tests whether the length of parameter 1 is the same as the length of parameter 2.Is numeric
Tests whether parameter 1 is a valid number (parameter 2 is unused)Is date
Tests whether parameter 1 is in a valid date format, based on the regional settings of the system (parameter 2 is not used)Is empty
Tests whether parameter 1 contains anythingContains
Tests whether parameter 2 is a sub-string (i.e. contained within) parameter 1.
Notes
The step fails if either parameter 1 or parameter 2 contains an unknown variable or otherwise invalid text. The step may also fail if AutoMate™ is set to start another task on a Then or Else condition, and that task is not available (for example, if it was removed from the task list).
See Also: