The wrtjoblog procedure is a utility to output an information message the joblog.
The wrtjoblog procedure can send a string of text to the job's joblog as an informational message. Up to 16 optional substitution variable may be specified and inserted in the the message text at runtime.
void wrtjoblog( szMsg * Value OPTIONS(*STRING) szSubstitutionValue1 * Value OPTIONS(*STRING : *NOPASS) szSubstitutionvaluen... * Value OPTIONS(*STRING : *NOPASS) ... up to 16 substitution values may be specified ) |
|
See also: WrtTrace |
The return value is *ON ('1') is the procedure was successful, otherwise *OFF ('0') is returned.
.....C*Rn01..............OpCode(ex)Extended-factor2++++++++++++++++++++++++++
C callp wrtjoblog('Customer: %s Balance due: %s' :
C %char(CustNo) : %char(BALDUE))
In this example the two numeric values CUSTNO and BALDUE are converted to character using %CHAR and used as substitution values in the joblog string. Of course non-numeric values may be specified without enclosing them in the %CHAR built-in function.
If CUSTNO = 3741 and BALDUE = 65.00 the message written to the joblog would be as follows:
Customer: 3741 Balance due: 65.00