Incorporate a ‘SIGNAL on SYNTAX’ routine within the rule or program to obtain and display any error messages that may be returned during a function call failure. Additionally, utilize a ‘TRACE I’ REXX statement when needed before the function call to obtain the logical trace activity within the invoking rule or program. This debugging code resembles:
/*--------------------------------------------------------------------*
/* Create Signal on Syntax routine to obtain any failure messages. *
/*--+----1----+----2----+----3----+----4----+----5----+----6----+----7*
signal on syntax
/*--------------------------------------------------------------------*
/* Add TRACE I if needed to trace logic flow of rule/program. *
/*--+----1----+----2----+----3----+----4----+----5----+----6----+----7*
trace I
varname = 'GLVPLXT0.VARTEST.1'
varval = 'TEST NUMBER 1'
setvar = OPSVASRV("CREATE NAME("varname") DATAVAL('"varval"')")
return
syntax:
do queued()
pull err_info
say 'Failure info from OPSVASRV='err_info
end
|
Copyright © 2013 CA.
All rights reserved.
|
|