.key address
.def address ${JAZBOSS}
 Cd JAZ:
 IF NOT EXISTS JAZ:JAZ.WPL
 Echo "JAZ must be run from the same directory where Jaz.wpl resides"
 QUIT
 ENDIF
 Search >NIL: S:User-Startup JAZ:
 IF $RC NOT EQ 0 
 ; Append a standard Application-Specific User-Startup
 ; use backtick execution to get the current directory to display
 Echo "Adding Assign JAZ: `CD` to S:User-Startup"
 Echo >>S:User-Startup ";BEGIN JAZ MAILER"
 ; use backtick execution to get the current directory to insert
 Echo >>S:User-Startup "Assign JAZ: `CD`"
 Echo >>S:User-Startup ";END JAZ MAILER"
 ENDIF
 IF <address> EQ "PANEL"
 ECHO "Loading JAZ Control Panel"
 SKIP panel
 ENDIF 
 IF NOT EXISTS JAZ:jaz.x
 Echo "JAZ is not configured yet"
 SKIP panel
 ENDIF
 Echo "Calling <address>"
 SetEnv calling <address>
 Assign XFERQ: T:
 LoadLib LIBS:rexxsupport.library
 ; Copy libs and change these libs/ to LIBS: for permanent installation
 LoadLib libs/xferq.library
 LoadLib libs/xprzedzap.library
 sys:rexxc/rxlib rexxsupport.library 0 -30 0
 sys:rexxc/rxlib xferq.library 0 -30 0
 rx "if ~show('p','LOGPROC') then address COMMAND 'Run >NIL: JAZ:LogProc'"
 LaunchWPL jaz jaz:jaz.wpl jaz jaz!startup 0 30000
 QUIT
 LAB PANEL
 LoadLib libs/req.library
 run >nil: JAZ:Cliva JAZ:jaz.p
 QUIT

