April 1, 2009 Hey, Ted
Does RPG have anything equivalent to CL’s Delay Job (DLYJOB) command? I am working on an RF application, and I need to code a delay of a few seconds into my program. Besides using a do loop with a final value of 1,000,000,000,000, how can I cause a timed interval within an RPG program?
Thanks to the wonders of the Integrated Language Environment, RPG has a way to delay a job a specific number of seconds. It’s called sleep. Sleep requires one 4-byte unsigned integer parameter–the number of seconds to delay–which must be passed by value.
Here’s an example: