Professional Documents
Culture Documents
D**************************************************************** ***** * D Main pr EXTPGM('RPGPCC') D Pruta 100 D Main pi D Pruta 100 * /free /end-Free
http://Iseriesvenezuela.blogspot.com. Ing. Liliana Surez. Programa en RPGLE Free para ejecutar comandos PC
C** Call the API to get the IP address C* C CALL 'QDCRDEVD' C PARM C PARM C PARM 'DEVD0600' C PARM @JOB C PARM C* C** Load the IP Address C* C MOVEL(P) IPADDR
4 8 10 256
@ADDR
/free // To Automatically open the file with the associated // application: // LINUX: xdg-open // MAC: open // WINDOWS: start commandString = 'STRPCO'; monitor; ExecuteCommand(%trim(commandString):%len(%trim(commandString))); on-error; endmon; pcCommand = 'start ' + %trim(pruta);
// STRPCCMD to open a PDF commandString = 'STRPCCMD PCCMD(''' + %trim(pcCommand) + ''') PAUSE(*NO)'; monitor; ExecuteCommand(%trim(commandString):%len(%trim(commandString))); on-error; displayString = 'ERROR occurred on STRPCCMD using QCMDEXC!'; DSPLY displayString; endmon; *inLr = *ON; /end-free