I'm trying to create a batch file which passes around a string with line feeds in it but its not working out. The continuation of the string is executed as a new command.
Is there anyway to encode a line feed or make this work?
I'm trying to create a batch file which passes around a string with line feeds in it but its not working out. The continuation of the string is executed as a new command.
Is there anyway to encode a line feed or make this work?
You can create directly multiline strings with the caret (one empty line is required).
Or you can create first a newline character.
An explanation how this works can be found at Explain how dos-batch newline variable hack works
Expansion to jeb answer , Adding !LF!^ to each line would be easy