Verbs and Built-in Functions › &ASISTR
&ASISTR
&ASISTR returns the following string, yet retains leading blanks.
&ASISTR is a built-in function and must be used to the right of an assignment statement.
&ASISTR returns the complete text, as is.
&ASISTR assumes any leading blanks are intended-assignment commences from the second character position after the &ASISTR keyword.
This built-in function has the following format:
&ASISTR text
Operand:
- text
-
Specifies one or more words or variables for assignment to the target variable.
Examples: &ASISTR
&SYSMSG = &ASISTR INVALID DATA ENTERED
&PRTLINE = &ASISTR NETWORK SUMMARY REPORT
Notes:
- &ASISTR is ideal when constructing error messages where the text is to be offset for display formats.
- &STR and &ASISTR are useful ways of assigning multiple words into a single string-do not use &CONCAT because it eliminates blanks between the fields being assigned.
- The total size of the constructed variable or constant cannot exceed the maximum size for a variable, that is, 256 characters (if it exceeds the maximum, it is truncated to 256 characters).
- &ASISTR differs from the &STR function in that it assigns data as is, and retains leading blanks (&STR scans for data starting after the &STR keyword and starts its assignment from the first data character).
- If &CONTROL DBCS, DBCSN, or DBCSP is in effect, &ASISTR is sensitive to the presence of DBCS data.
More information:
&STR
&LBLSTR
&NBLSTR
&TBLSTR
|
Copyright © 2009 CA.
All rights reserved.
|
|