|
Answer» How do I not overwrite text when writing to a file? :-?
For example...
Code: [Select] set TEXT1=Hello. set text2=How are you doing. echo %text1% > C:\Text.txt echo %text2% > C:\Text.txt
After this how do I make sure it goes to the next line like
Code: [Select] Hello. How are you doing.
Instead of this
Code: [Select] Hello.How are you doing.
Or does it do it on its own?
Is there another way to write text to a file rather then echo or is this the most efficient way?
Use >> to APPEND to a file, as in
set text1=Hello. set text2=How are you doing. echo %text1% > C:\Text.txt echo %text2% >> C:\Text.txtThanks, and I see it ALREADY PUTS it on the next line.
|