Chapter 4. RPG IV Indicators

An indicator is a one byte character field which contains either '1' (on) or '0' (off). It is generally used to indicate the result of an operation or to condition (control) the processing of an operation.

The indicator format can be specified on the definition specifications to define indicator variables. For a description of how to define character data in the indicator format, see Character Format and Position 40 (Internal Data Type). This chapter describes a special set of predefined RPG IV indicators (*INxx).

RPG IV indicators are defined either by an entry on a specification or by the RPG IV program itself. The positions on the specification in which you define the indicator determine how the indicator is used. An indicator that has been defined can then be used to condition calculation and output operations.

The RPG IV program sets and resets certain indicators at specific times during the program cycle. In addition, the state of most indicators can be changed by calculation operations. All indicators except MR, 1P, KA through KN, and KP through KY can be set on with the SETON operation code; all indicators except MR and 1P can be set off with the SETOFF operation code.

This chapter is divided into the following topics:



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