|
I find inserting quotes to be a real pain so I have come up with the following method which works well for me: DCL VAR(&DBLQTE) TYPE(*CHAR) LEN(1) VALUE('"') CHGVAR VAR(&PCCMD) VALUE(&DBLQTE *CAT '\\' *CAT &IPADR + *TCAT &FULLPATH *TCAT &DBLQTE) Allen DRV Technologies 866.378.3366 www.drvtech.com ************************************************ Automate the delivery of iSeries reports electronically, without programming to eliminate printing and manual distribution. SpoolFlex automated commands give users their reports in the electronic format they require (such as PDF, Excel and Word), distributed where they need them, without hardware. Call for a free demonstration. -----Original Message----- From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Peter Vidal Sent: Wednesday, July 26, 2006 12:08 PM To: midrange-l@xxxxxxxxxxxx Subject: RE: STRPCCMD Hi list! I was surfing on the archives and this issue was submitted once for discussion and that issue was resolved. However, I have a variant of it that I need to resolve. I am doing this on my code when trying to process a file called COPY OF DETAILDATA.TXT: ================================================ PGM PARM(&OBJ) DCL VAR(&OBJ) TYPE(*CHAR) LEN(1000) DCL VAR(&SYSPATH) TYPE(*CHAR) LEN(1000) RTVNETA SYSNAME(&SYSTEM) MONMSG MSGID(CPF0000) EXEC(DO) CHGVAR VAR(&MSG) VALUE('ERROR: Cannot access network attribute.') GOTO CMDLBL(END) ENDDO CHGVAR VAR(&SYSPATH) VALUE('"\\' *CAT &SYSTEM *TCAT '\ROOT\TEST\' *CAT &OBJ *TCAT '"') STRPCO MONMSG MSGID(CPF0000) STRPCCMD PCCMD(&SYSPATH) PAUSE(*YES) ENDPGM ================================================ However, is not working for me. I have the PC message: '\\TT400\ROOT\TEST\Copy' is not recognized as an internal or external command, operable program or batch file. When I debug the variable &SYSPATH , its value before the STRPCCMD command is: "\\TT400\ROOT\TEST\Copy of DETAILDATA.txt I can't find the double quotes I am inserting in the variable and I am using *TCAT so I can truncate blanks at the end of the &OBJ variable, but this is not working. What I am missing? TIA, Peter Vidal PALL Corporation / SR Programmer Analyst, IT Development Group 10540 Ridge Rd., Ste 203, New Port Richey, FL 34654-5111 http://www.pall.com "Man's mind, once stretched by a new idea, never regains its original dimensions." Oliver Wendell Holmes (1809-1894)
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.