Inserting conditional transaction fields into a transaction description

To insert conditional transaction fields:

  1. Put your cursor in the transaction field below where you want the #If transaction field to be inserted.

  2. Find and select #If in the Available fields box, and add it by clicking the arrow button.

  3. images\properties-button.gif Click the Properties button to open the Properties dialog.

  4. In the Expression box, type an expression that represents the condition you want FORMS to check. More info.

  5. Click OK to close the Properties dialog.

  6. Repeat the above steps, except for the expression, to insert #ElseIf and #Else transaction fields (optional) and an #EndIf transaction field. (#EndIf needs no expression.)

Later, when you transfer your data using the transaction description, Transfer checks the return value of your expression for each form. If the expression is true (that is, if the return value ¹ 0), FORMS includes in the record data resulting from all the transaction fields between #If and #EndIf, except for those following #ElseIf and #Else. If the expression is false (that is, if the return value = 0), FORMS looks for the optional #ElseIf and #Else fields and, if a return value ¹ 0, inserts the data resulting from the fields following it.

Limitations of conditional transaction fields

Transaction descriptions: Overview

Transaction description dialog