contact image

Self Submitting RPG


DOWNLOAD
Download text files

This program will prompt users for input via display file. Then submit itself to batch to process.  This program uses a tool purchased from company RJSSoftware to email reports. We do have source available on this website to do all the functions of this software.(SNDDST)
Notice the display file is USROPN (user open) also notice we have defined variables for the API QUSRJOBI. This API is used to determine if the program is running interactive or batch.
Also....even with a *Entry plist you may call a program without those parameters as long as they are not referenced.

Use the USROPN keyword to manually control opening/closing of display file

 
     
     FASWPICKD  CF   E             WORKSTN UsrOpn
 
Example - QUSRJOBI - Is this job interactive or Batch
 
      *+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
      *   IsIntJob   --   Is this an interactive job?
      *        returns *ON if job is interactive
      *            or  *OFF if job is not interactive.
      *+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
     D   RcvVar        s          32766A
     D   RcvVarLen     s             10i 0
     D   Format        s              8A
     D   QualJob       s             26A
     D   InternJob     s             16A
     D   ErrorCode     s          32766A
     D dsJob           DS
     D  dsJobBytesRtn                10I 0
     D  dsJobBytesAvl                10I 0
     D  dsJobName                    10A
     D  dsJobUser                    10A
     D  dsJobNumber                   6A
     D  dsJobIntern                  16A
     D  dsJobStatus                  10A
     D  dsJobType                     1A
     D  dsJobSubtype                  1A
     D  dsJobReserv1                  2A
     D  dsJobRunPty                  10I 0
     D  dsJobTimeSlc                 10I 0
     D  dsJobDftWait                 10I 0
     D  dsJobPurge                   10A
    
     C*
     C                   Eval      RcvVarLen = %Size(DsJob)
     C*
     C                   Call      'QUSRJOBI'
     C                   Parm                    DsJob
     C                   Parm                    RcvVarLen
     C                   Parm      'JOBI0100'    Format
     C                   Parm      '*'           QualJob
     C                   Parm      *Blanks       InternJob