Chapter 4-2: True/False Status Indicators Cover Page Statements That Affect T/F Status IndicatorsT/F Execution Condition Values

Some Examples of T/F Usage


Consider the following series of statements as examples of how T/F status indicators are set and T/F execution conditions are evaluated.

          READ     TAR RECEIPT1               HOLD 0 FT 0 BY RECEIPT1 KEY

If the READ statement is successful in this example, the level 1 true/false status indicator is set to T; otherwise it is set to F.

          READ     TAR RECEIPT1               HOLD 0 FT 0 BY RECEIPT1 KEY
    T     IF       TAR RECEIPT1 POST STARTED      EQ     1

Here we have added an IF statement following the READ with a T in the first character position. Thus, the IF statement will execute only if the level 1 internal true/false status indicator is T (meaning the READ statement was successful). Assuming the READ is successful, the IF statement executes and sets the next level of internal true/false status indicators (in this case, level 2). Note that the IF statement as coded is an example of a single statement which both checks an execution condition and, if executed, sets a status indicator.

Continuing with our example statements:

          READ     TAR RECEIPT1               HOLD 0 FT 0 BY RECEIPT1 KEY
    T     IF       TAR RECEIPT1 POST STARTED      EQ     1
    TT    SET      TAR WORK FLAG                  =      0
    TF    END

Now we have added statements that act upon the result of the evaluation of the IF statement but if and only if the READ statement was successful. If the IF statement is true, the SET statement executes; otherwise, the END statement executes. However, if the READ statement was not successful, none of the statements following the READ are executed.

 

APPX Application Design Manual (01/13/03) Cover Page Statements That Affect T/F Status IndicatorsT/F Execution Condition Values

© 2003 by APPX Software, Inc. All rights reserved