CPYTOIMPF FROMFILE(SARKNS/ENQP003) TOSTMF('C:/Documents and Settings/user/exc.xls') MBROPT(*REPLACE) RCDDLM(*LF) DTAFMT(*iso)
Here I have created a Excel book with name exc.xls , my requirement is to copy all the records from my physical file (sarkns/enqp003) to the desired excel book.
when i run this command I am getting message zero records are copied .
CPYTOSTMF can copy to a folder on the IFS - the 400rd drive not to your pc I don't think it can write an xls file .. a comma delimited which excel can pick up -- but not formated. Phil
Where I've needed to output comma delimited files, I've built the record(s) into a single-field file, then copied (or FTP'd) the file out with the .csv extension - Excel will pick that up with no additional formatting required.
Copy command can write to IFS: COPY OBJ('qdls/TempFldr/Insrpt2.xls') TODIR('qntc/accdc01/InterDocs') TOCCSID(*CALC) DTAFMT(*BINARY) REPLACE(*YES))
Last Answered:
Jul 10 2009 12:58 AM GMT by Cunninjoe 310 pts.