NOMAIN

The NOMAIN keyword indicates that there is no main procedure in this module. It also means that the module in which it is coded cannot be a program-entry module. Consequently, if NOMAIN is specified, then you cannot use the CRTBNDRPG command to create a program. Instead you must either use the CRTPGM command to bind the module with NOMAIN specified to another module that has a program entry procedure or you must use the CRTSRVPGM command.

A no-main module will not include logic for the RPG program cycle; thus language features dependent on the cycle must not be specified.

Note:
In addition to the NOMAIN keyword, the MAIN keyword also allows you to create a module that does not contain the RPG program cycle.

See Linear Module for more information.



[ Top of Page | Previous Page | Next Page | Contents | Index ]