On windows , I have 2 csv files that I am attempting to combine into a single csv file. There may be better ways to do this but I was using the dos command
copy file1.csv + file2.csv=file3.csv which works. However when I try to run this command as part of an action script I cannot seem to make it work as I think relevance’s copy command is being used.
I have tried variations of the following but I cannot get it to work. I run two previous scripts in this same action that creates the first two files and those exist.
// create account4.vbs
createfile until __the_end
dos copy c:\windows\CIP1accounts.csv + c:\windows\CIP2accounts.csv = c:windows\CIPcombined.csv
I just tried this and I get exit code 1 as I did running the copy command. when I run both commands from the command prompt they work. However in the script they don’t as I get exit code 1
from the windows directory which works. type CIPCombinedaccounts1.csv CIPCombinedaccounts2.csv > CIPcombined.csv
From the script
// create account4.vbs
createfile until __the_end
dos type c:\windows\CIPCombinedaccounts1.csv c:\windows\CIPCombinedaccounts2.csv > c:windows\CIPcombined.csv
delete __createfile
createfile until EOF_EOF_EOF
{concatenation "%0d%0a" of lines of file "c:\windows\CIP1accounts.csv"}
{concatenation "%0d%0a" of lines of file "c:\windows\CIP2accounts.csv"}
EOF_EOF_EOF
delete c:\windows\CIPcombined.csv
copy __createfile c:\windows\CIPcombined.csv