11.07.2015 Views

NetEx EFT213 Reference Manual Rel 5.4

NetEx EFT213 Reference Manual Rel 5.4

NetEx EFT213 Reference Manual Rel 5.4

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Figure 2. Nested String SubstitutionThe example above sets the <strong>NetEx</strong>/eFT input prompt to either the value of variable myprompt (if it is defined),or else to the string eFT>. Since there exists nested string substitution, <strong>NetEx</strong>/eFT first processes theinnermost one (labeled string sub1 above) to evaluate the variable myprompt. The double quotes outside of{myprompt} turns the resulting value into a string literal that is then used as the second argument to the dfn()function. Once this is done, <strong>NetEx</strong>/eFT processes the outermost string substitution syntax (labeled stringsub2 above).All string substitution processing is performed by <strong>NetEx</strong>/eFT from the inside out. This is important to keep inmind when creating such things as custom prompts or scripts. Since the inside string substitution syntax isprocessed first, it is treated as a separate entity in itself. This is significant because it affects the use of doublequotes for string literals. Normally double quotes must be escaped when they are used within another set ofdouble quotes in order for <strong>NetEx</strong>/eFT to take them literally. However, if the outer set of double quotes is notpart of the immediate string substitution syntax containing the inner set of double quotes, then the inner set ofdouble quotes should not be escaped. The following example illustrates this point.eFT> ask -prompt "{upper("enter your name")}" nameSince the outer set of double quotes (“{...}”) is outside of the string substitution syntax, the inner set shouldnot be escaped. This is because the string substitution syntax is processed first, resulting in the nonquotedstring ENTER YOUR NAME. The outer set of quotes then is applied to that string and the remainder of thecommand is processed.Developing <strong>NetEx</strong>/eFT Scripts Using Input Files and Aliases<strong>NetEx</strong>/eFT was designed to be very easy to use for all types of users. The commands are simple and the syntaxis straightforward. However, it is often the case that a site wants to customize the <strong>NetEx</strong>/eFT interface tobe even more simple or familiar for its users. This customizing is generally done by more sophisticated<strong>NetEx</strong>/eFT users then handed back to the general user base. This section addresses the areas important to developing<strong>NetEx</strong>/eFT scripts.A script can be in the form of an input file or an alias; <strong>NetEx</strong>/eFT treats them the same internally. The differenceis in the way they are defined. Input files are created using a standard text editor. Aliases are createdusing the SET ALIAS command and require special command line syntax. The examples that are given inthis section, although they apply to all types of scripts, are generalized to emphasize the topic of discussionREF-eFT213-R<strong>5.4</strong>-08 Advanced Local User’s Guide Page 89

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!