Previous Topic: Argument SubstitutionNext Topic: CLIST Enhancements


Argument Substitution Rules

Values are substituted into variable symbols according to the following rules:

  1. A single command string can contain up to 16 discrete variables (@1 through @16).
  2. Sometimes the variable symbol combined with the literal string yields unpredictable results. Use a period (.) to remove ambiguity.

    For example:

     I DCMT V PR BUGA0@160 NCI
    

    In this case, @160 could be interpreted as either @1 or @16, with @16 being assumed. If you use a period to delimit the variable, however, it is clear that the variable is @1:

     I DCMT V PR BUGA0@1.60 NCI
    
  3. You can use a variable symbol more than once in a substitution string. For example, if the substitution word is DEBUG, the following string:
     I @1 @1 PROGRAM
    

    yields

     I DEBUG DEBUG PROGRAM
    
  4. Any value in the command can be symbolized. For example, in the command ADS ICD@1, you can replace the variable @1 with the rest of the dialog name.
  5. Use the TIE character (_) to substitute multiple words for a single symbol. For example:

    Assume that the command "@2 DCMT @1" is assigned to a PF key. If "I" is to be substituted for variable @2 and "D AC TA" for variable @1, you must use the TIE character and enter variable @1 as "D_AC_TA." A space replaces each TIE byte to yield:

     I DCMT D AC TA
    
  6. Substitution words are numbered sequentially according to their position in the input data stream. Thus, if you enter the values A B C D, value A is substituted into variable @1, B into @2, C into @3, and D into @4.
  7. If a substitution string contains a variable symbol, but no substitution word is supplied, a single space replaces the symbol.In the example &od. DCMT @1", if you entered "D_AC_TA" as the only substitution word, the result would be the command:
     DCMT D AC TA
    

    "D_AC_TA" is substituted into variable @1; and because no other word was entered, a space replaces variable @2.