Prompts for and accepts input from the terminal.
IP{c{r}}
c is an optional prompt character.
If c is used, it remains in effect until reset with a new IBN, IBP, IN, or IP command.
If c is not used, it defaults to the last prompt character used or to a colon (:) if no other character is specified.
r is a direct or indirect reference to a buffer or select register where the input data is to be placed.
IP{c} places data in the active input buffer, replacing the existing parameter pointed to by the buffer pointer.
IPcr places input in the buffer or select register specified by r. The prompt character is required in this case.
Leading and trailing blanks are removed and embedded blanks are replaced with a single attribute mark, thereby replacing the current parameter in the input buffer with multiple parameters. If the input is to a file buffer attribute (as specified by r) and contains embedded blanks, the embedded blanks are replaced with a single attribute mark as above. The attributes then replace consecutive attributes in the item. For example:
If you enter "ABC DEF GHI" when the command,
IP?&3.2
is executed, the values "ABC", "DEF", and "GHI" would replace attributes
two, three, and four, respectively, in file buffer 3.
If you want to retain blanks input at the terminal and treat the input text as a single attribute, use the IBP command.
Pressing RETURN only in response to an input prompt nulls the current parameter as pointed to by the buffer pointer.
The input buffer pointer does not change position after an IP command.
Note: The IP command does not read stacked input the way an INPUT statement in DataBasic does. All input commands in Proc ignore stacked data.
Command Input | PIB Before | PIB After |
---|---|---|
IP? |
UPDATE^INV ![]() |
UPDATE^INV^3-9393 ![]() |
Command Input | PIB Before | PIB After |
---|---|---|
IP: |
3^234^56^78^ ![]() |
3^XXX^YY^56^78 ![]() |
Command Input | PIB Before | PIB After |
---|---|---|
IP? RETURN |
ABC^DEF^GHI ![]() |
ABC^^GHI ![]() |
Command Input | File Buffer 1 Before | File Buffer 1 After |
---|---|---|
IP:&1.1 |
000 AB-221 002 2500 |
000 AB-221 002 2500 |
Command Input | File Buffer 4 Before | File Buffer 4 After |
---|---|---|
IP?&4.1 |
000 2831 |
000 2831 |