.UTIL SUBR CREATE
This utility adds a subroutine to the Application. Added in 5.2.0
Usage:
PASS <process_name> FIELD SHARE? N
PASS <process_desc> FIELD SHARE? N
PASS <Application> FIELD SHARE? N
PASS <Version> FIELD SHARE? N
GOSUB --- .UTIL SUBR CREATE
* Check for errors
IF --- .UTIL SUBR CREATE NE
Description:
This utility adds a subroutine to the specified Application/Version.
<process_name> is the name of the subroutine want to add (Required). This parameter is required, if it is missing, the subroutine will CANCEL.
<process_desc> is a description of the process (Optional). If not PASSed or PASSed blank, it will default to the Process Name.
<Application> is the Application where the process should be added (Optional). If not PASSed or PASSed blank, it will default to the current application.
<Version> is the Version where the process should be added (Optional). If not PASSed or PASSed blank, it will default to the current version.
The subroutine will be added to the specified application. You can then begin adding statements to the subroutine via
.UTIL SUBR WRITE ILF.
Also see
.UTIL SUBR CLOSE and
.UTIL SUBR DELETE.
Note that the .UTIL SUBR * group of routines share certain internal fields therefore you can only use them in a process family with share class SUBPROCESS. In other words, don't call .UTIL SUBR CREATE in one process, then .UTIL SUBR WRITE ILF in another process that you have invoked Related or Detached.
If you are repeatedly creating a subroutine, running it, then deleting it and re-creating it (same name, different code) within one process family, then you must invoke your subroutine with a SUBR .... command and RELATED or DETACHED share class. If you just use a GOSUB or a SUBR .. SUBPROCESS, APPX will just use the first cached version of the process and will not create a new Em for each invocation.
Comments:
Read what other users have said about this page or add your own comments.
--
JeanNeron - 2012-06-20