The &MAIPUT verb builds a data stream for the PLU (application), either as an automatic reply to data received from the PLU or to replace a data stream received from the SLU (terminal) before sending it on to the PLU.
&MAIPUT fills in the input fields on the panel that is the current logical screen image. Multiple &MAIPUT statements are issued to build up the data stream. Each one supplies the contents of one input field. &MAIPUT statements are used to reply to PLU data, or to change the input from the terminal (SLU) before sending it on to the application using &MAICONT.
This verb has the following format:
&MAIPUT [ ROW=n ]
[ COL=n ]
data
Operands:
Indicates the screen row position of the input field. If ROW is not specified but COL is, ROW=1 is assumed.
Indicates the screen column position of the input field. If COL is not specified but ROW is, COL=1 is assumed.
Specifies the data to be contained in the input field. The data starts at the first non-blank character after any operand, and ends at the last non-blank character on the statement. A variable or variables is specified as the data. If no data is specified, but ROW=, COL=, or both are specified, a null input field is generated, the equivalent of pressing the EOF key in an input field.
If data is specified, but both ROW= and COL= are not specified, an unformatted field is generated, consisting of only data with no Set Buffer Address sequence. This form of input results from a screen with no set input fields defined, where the whole screen is available for input.
If data, and ROW=, COL=, or both are specified, a field with a Set Buffer Address sequence followed by the data is generated.
Examples: &MAIPUT
&MAIPUT ROW=24 COL=6 SHOW USERS &MAIPUT TRN1 &MAIPUT ROW=2 COL=1
&MAIPUT ROW=1 COL=1 SPF 2 &MAICONT PLU
Notes:
The supplied row and column values must be within the dimensions of the current screen, otherwise an error results.
An &MAICONT PLU statement (or equivalent) is used to send the generated data stream to the application. The &MAIINKEY and &MAICURSA statements are used to provide a value for the attention key to be generated and a cursor address at time of input.
&MAIPUT with no operands is used to prepare a data stream with no modified fields. In this case, you can use &MAIINKEY to specify the key to press and &MAICURSA to specify the cursor address.
An &MAIPUT issued when there is no data outstanding is normally ignored. Data is outstanding from the time an &MAIREAD is satisfied until an &MAICONT, &MAIDEL or another &MAIREAD is issued. However, in the case of a script procedure started using a .S session skip command or session cleanup, an &MAIPUT is allowed before the first &MAIREAD. An &MAIPUT PLU is also allowed after the time interval specified on an &MAIREAD WAIT= verb expires.
| Copyright © 2009 CA. All rights reserved. |
|