I using RPG IV, and the OS/400 is V4R3 and the RPGLE is V4R2.
I have a program which uses a logical file XOLDCD. The program encounters
the following problem. It is not able to allocate the file XOLDCD because
it is used exclusively by another process.
The error messages are:
Message Data . . . . . . . . . . . . . :
Error message CPF4128 appeared during OPEN for file XOLDCD.
Message Identifier . . . . . . . . . . : CPF4128
Not able to allocate objects needed for file in library
According to my knowledge, RPG IV does offers Error handling *PSSR.
However, it does not seem to work. The following are sample of statements
in my program:
FXOLDCD IF E K DISK
D PSDS SDS
D Procedure *PROC
D Status *STATUS
C *PSSR BEGSR
C Status IFGT 99
I do not wish to allocate the file in the CL before calling this program,
because it will involve to much changes to my system. I hope someone can
advice me how it can be achieve without using a CL