Defining Procedure Formulas

Top  Previous  Next

Creating conditional expressions with the Formula Editor actually creates structures in the source code. There are three structures you can create with the Formula Editor--a simple assignment expression, or an IF or a CASE structure. You can also nest either of these structures, creating complex conditional statements.

The Formula Editor creates simple (unconditional) assignments, the Conditionals dialog creates complex conditional assignments, and the Formulas dialog manages these formulaic assignments for your procedure. See:

How to Create a Simple Assignment Expression

How to Create a Complex Assignment Expression

Usually, you'll want to display the result of your assignment in a string control in a window or report. To display it in a window:


Press the Window button to open the Window Designer.


Select the STRING control from the controls Toolbox, and DRAG to the window to place the control.


With the new string control selected, choose View Properties (or RIGHT-CLICK on the string and choose Properties from the popup menu).


Set the VariableString property to TRUE in the Properties Pad dialog.


Highlight the Use property and press the ellipsis button to select the variable which contains the result of your formula.


Type a valid display picture in the Text property field.


Choose Save and Close to close the Window Designer and return to the Procedure Properties dialog.