When writing a script
or modifying an existing script, pay special attention to the WAITFOR
and the TYPE statements. To ensure that the script recognizes the
expected prompt during each stage of sign-on, specify the exact sequence
of prompts and responses for the server.
You might test the sequence
by experimenting at the server by going through the process that you
want to capture in the WAITFOR and the TYPE statements. For each display
at the server, choose a word from that display for the WAITFOR statement.
Capture in a TYPE statement the information that you type in response
to a display. Be sure to note all carriage returns or other special
keys.
For example, if TSO
is the server and you need to use a TYPE statement in a sign-on script
whose length is greater than 80 characters, divide the TYPE statement
into two or more TYPE statements.
To divide the TYPE statement,
insert a hyphen (-) at the division point. The remote TSO machine
interprets the hyphen as the continuation of the TYPE statement from
the previous line.
For example, consider
the following TYPE statement:
type "sas options ('dmr comamid=tcp')" enter;
To divide the statements,
change it to the following:
type "sas options ('dmr comamid=-" enter;
type "tcp')" enter;
Note: Do not insert spaces around
the hyphen.