Navigation:  Reference > Structured Programming Commands >

General Information:  Structured Programming Commands

Print this Topic Previous pageReturn to chapter overviewNext page


There are five different structures that can be used within a program.  Each one is a little different and would be used in specific situations.  Often the decision to use a specific structure is strictly due to your likes or dislikes.


In the examples given below, the beginning and ending lines of the structure are given, and the possible loop options are shown within the structure.  There is no requirement to use any of the 'intrastructure' options; however, the beginning and ending commands are required to form the structure properly.  Each structure type can be nested up to 20 deep.  For example:


       IF x = y

          IF z = 1

            IF q = 1 .AND. test = 'abc'

                 //... etc. till there are 20 IF/ENDIF pairs





You can insert other structure types, and those other structures will not count towards the 20 total.  The indentations above are just for example only and are not required.



Page url: