Apostrophi
Apostrophi

Reputation: 9

How to Generate Spool File in AS400?

I was doing the code change. After compiling the programs in RPG i want to do the testing. But when i run the command i am not able to get spool file for that run of command. Please help. Thanks in Advance!

Upvotes: 0

Views: 2241

Answers (1)

Charles
Charles

Reputation: 23793

Assuming you're correct and that the program creates a spool file...

Sounds like it's being sent to a printer automatically. By default, once a spool file is printed it gets deleted from the system.

Try doing the following before running your program:

OVRPRTF FILE(MYPRTF) HOLD(*YES)

You'll need to use the name of the printer file used by your program in place of MYPRTF. The HOLD(*YES) will prevent the spool file generated from the printer file from being sent to the assigned printer.

Upvotes: 2

Related Questions