home *** CD-ROM | disk | FTP | other *** search
- .pg wi full clr cy
- COMMAND NAME»gray«: »%t« GetString »ye«
-
- /GETS[TRING] {variable} {default} {Prompt} [[{length}] UC]
- /cw
- Gets a string from the user and assigns it to »cy«{variable}»#« if
- »bo«<Enter>»#« pressed with no string entered, the »cy«{default}»#« is
- used.
- .pg
-
- »wh«{variable}»#« is a string variable name.
-
- »wh«{default}»#« is a string variable holding the default value
- that will be used if the »bo«<Enter>»#« key only is
- pressed.
- .pg
-
- »wh«{Prompt}»#« The prompt that will be displayed for the
- user. If the »cy«{prompt}»#« contains »ma«spaces»#« or
- »ma«commas»#«, it must be enclosed in quote marks.
-
- »wh«{length}»#« The maximum length of the string that will be
- used. If it is zero ("»ye«0»#«") or null then the
- maximum string of »ye«254»#« characters will be
- accepted.
-
- »wh«UC»#« Optional token that indicates that the
- response should be set to »ye«all caps»#«.
-
- .pg clr
-
- Here are some examples with results displayed. »cy«{default}»#« is set
- to "»ye«NONE»#«". Press »bo«<enter>»#« to execute each command.
-
- /SET default NONE
- |/GETS Answer Default "What is your first name? "
- |Your first name is: »ma«%Answer»#«
- .reset
-
- |/GETS Answer Default "What is your zip code? " 5
- |Your zip code is: »ma«%Answer»#«
- .reset
-
- |/GETS Answer Default "What is your street address? " 32 UC
- |Address: »ma«%Answer»#«
-
- /ENDEXEC CLEAR
-