ddocImg01R pr extpgm('DOCIMG01R') d iDocID 100a const d iVersion 9p 0 d rtnIFSFile 255a d errRtn 1a
Passing this to iVersion... | Returns... |
-1 | The most recent revision. |
-2 or 0 | The initial version. |
A positive numeric value. | The specified version if it exists. |
CL0N01Factor1+++++++Opcode&ExtFactor2+++++++Result++++++++Len++D+HiLoEq....Comments++++++++++++ C eval theirDocID = ‘the one he is working with’ C eval theirVersion = -1 C callp docimg01r(hisDocID : theirVersion : theirRtnFileVar : theirErrRtn)
PGM DCL VAR(&DOCID) TYPE(*CHAR) LEN(100) DCL VAR(&VERSION) TYPE(*DEC) LEN(9) DCL VAR(&IFSFILE) TYPE(*CHAR) LEN(255) DCL VAR(&ERROR) TYPE(*CHAR) LEN(1) CHGVAR VAR(&DOCID) VALUE('AS400DOC-000000000038088') CHGVAR VAR(&VERSION) VALUE(-1) CALL PGM(RJSIMAGE/DOCIMG01R) PARM(&DOCID &VERSION + &IFSFILE &ERROR) ENDPGM
Still have questions? We can help. Submit a case to Technical Support.