Example: A message subfile using DDS
This example shows how to define a message subfile. The display shows the message subfile.
MESSAGE SUBFILE
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
The following keywords are important in the example:
SFLMSGKEY
SFLPGMQ
SFLMSGRCD
SFLPGMQ
SFLMSGRCD
Records in the subfile are messages from a message file.
Legend:
- (1)
- Specifying the SFLMSGRCD keyword on the subfile record format identifies this subfile as a message subfile. The parameter value specified causes the subfile to appear on line 3 of the display.
- (2)
- The fields MSGKEY and PGMQ are user-defined names given to the two fields
required for the subfile record format for a message subfile. The only specifications
allowed for them are their names and the SFLMSGKEY and SFLPGMQ keywords, in
the order shown.
This subfile is built by a series of output operations to SFLR that place messages in the subfile as subfile records. Messages are truncated to fit single lines (76 characters or 128 characters, depending on display size), and second-level help is available. This subfile is displayed by an output operation to SFLCTLR with option indicator 01 set on.
- (3)
- This subfile is paged by the IBM® i operating system when the display station user presses a Page Up or a Page Down key. The SFLEND keyword allows the IBM i operating system to display a plus sign whenever the subfile can be paged up.