CALL "C$EASYOPEN" USING fileName [csFlag] GIVING returnCode |
fileName | PIC X(n) | Specifies the name of the file to be open. |
csFlag | PIC 9 | This optional parameter is evaluated in thin client environment. Set it to 0 or omit it in order to open the file on the server. Set it to 1 in order to open the file on the client. In order to open the file on the client, the routine downloads it in the user temp directory on the client machine, then it opens it from there. |
0 | Operation successful. |
1 | File not found. |
2 | An error occurred during the copy from server to client in thin client environment. |
3 | Generic error. The most common causes are: • invalid or missing parameter • there is no program associated to the fileName extension • a Java exception occurred due to missing or incompatible runtime items (only with JDIC method) |
*> define retCode as pic 9(n) call "c$easyopen" using "c:\myapp\pdfs\custreport.pdf" giving retCode if retCode not = 0 display message "custreport.pdf could not be open" end-if. |