I’m having problems with the following code:
FOR /f "tokens=*" %%A in (%MYFILE_PATH%) do (
[other stuff]
echo %%A>> "%MYFILE_PATH%.scratch"
)
The file being read has XML in it and when < and > signs are read, the script throws errors.
How can I escape the contents of %%A to safely echo to the output file?
I don’t want to put double quotes around it since it will then echo the quotes too.
Thanks
When appending the contents of %%A into another file, all that you are essentially doing is copying the file.
EDIT