HP 3000 Manuals

GET [ HP RPG/XL Utilities-Part 2 RISE ] MPE/iX 5.0 Documentation


HP RPG/XL Utilities-Part 2 RISE

GET 

GET is used when you wish to execute a sequence of commands previously
stored in a file.

Form 

     G[ET] filename

Parameter Explanation 

filename         The name of the file containing the commands.

Purpose 

The GET command is used when you have a number of commands stored in a
file which you wish to have executed again at another time.  Using "GET
filename", you first have the commands displayed at the terminal.  They
are then executed automatically until the End of File (EOF) of the
command file is reached.

The command file--the file whose commands "GET" executes--is where you
imbed special specifications for the command.  For example, a comment may
appear in the command file by specifying an asterisk (*) as the first
character in a new line.

You may use the GET command to activate the softkeys to execute commands.
The function of a particular softkey may be accomplished indirectly by
putting the numbers 0 through 8 on a single line in the command file
where 0=ENTER key, 1=F1 (special function key 1), 2=F2, up to 8=F8.
Before entering an integer from 0 to 8, you must enter a Block mode
command so that the softkeys will be activated.

You may wish to review the commands that are displayed on the screen
before they are automatically executed.  You do so by setting pauses to
delay execution.  To do this, you specify "#n" where "n" equals the
number of seconds of pause you require.  If "n" is not specified, the
pause is turned off.  It stays in effect on every command until you
change it with another "#n".  The maximum value of "#n" is approximately
2,147,484 seconds.

Additionally, "%" on a new line will suspend the operation of RISE until
any of the special function keys is pressed while in Block Mode or until
the Carriage Return key is pressed while in Line Mode.  When the
appropriate continuation key is pressed, RISE will continue executing the
remaining commands from the command file.

If the command file contains an ADD command, RISE will enter ADD mode.
Control is then returned to you so that you can enter new text as
desired.  When you exit ADD mode, RISE will resume control and continue
to execute commands from the command file.  You cannot imbed new text in
the command file and expect RISE to enter it the way it executes other
commands.  In this respect, ADD is not automatically governed by GET as
other RISE commands are.

Similarly, if the command file contains a Modify command, RISE will enter
Modify mode and then return control to you.  You then type in your Modify
subcommands from your terminal.  RISE will not read and execute
subcommands stored in your command file with the Modify command.

You cannot imbed the GET command within a command file.  It can only be
issued at the terminal.


NOTE An example of the use of the GET command is RISETOUR. You may text in RISETOUR.PUB.SYS and list it offline to a line printer to see an example of a command file.
Examples The following is a legal abbreviation which may be used with the GET command and its parameter: G CMDFILE The RISE commands imbedded in a file named CMDFILE will be read and executed. As an example of a file that might be used with the GET command, a brief file is created. It is somewhat self-explanatory. Note the asterisks preceding the comments in lines 1/7 (1). In line 8, TEXT SIMCAL is entered. Following that is a command to LIST ALL (2). The pause in line 17 is incorrectly entered and must be modified to be acceptable to RISE (3) (5). The SHOW FIRST command is imbedded, followed by a series of 5's entered from lines 18 through 23. If the file were being run, through the use of the GET command, SHOW FIRST would bring the Header Specification form to the screen. The number 5 would operate as if special function key #5 were being pressed, and you would Scroll Forward to the next Record Specification form after the pause had been completed (4). In line #26, <Control Y> is used to exit ADD mode. MODIFY is used to insert the pound sign (#) before the pause (5). CMDFILE is then stored as a permanent file using the KEEP command (6). >ADD Creating work space file. (1) 1 :* THIS IS A SAMPLE COMMAND FILE. 2 :* AN ASTERISK INDICATES A COMMENT LINE. 3 :* YOU STORE A SEQUENCE OF COMMANDS IN A 4 :* FILE TO HAVE THEM ALL EXECUTED 5 :* AUTOMATICALLY. 6 :* 7 :* TEXT IN A FILE. (2) 8 :TEXT SIMCAL 9 :LIST ALL 10 :* 11 :* LET'S USE SHOW MODE TO AUTOMATICALLY 12 :* SCROLL THROUGH THE FILE WITH THE RPG 13 :* SPECIFICATION RECORD FORMS. 14 :* 15 :* WE SHOULD TURN THE PAUSE ON SO THAT WE 16 :* HAVE TIME TO REVIEW THE SPECIFICATIONS. (3) 17 :20 (4) 18 :SHOW FIRST 19 :5 20 :5 21 :5 22 :5 23 :5 24 :EXIT NOW 25 :* ALL DONE WITH COMMAND FILE. 26 :<Control Y> > (5) >M17 17 20 :I# 17 #20 : (6) >KEEP CMDFILE Keep completed. File name is CMDFILE > >


MPE/iX 5.0 Documentation