Best way to insert/remove line in text file?
Posted: 02 Aug 2009 22:30
Hello all,
Have learned a lot here and thanks for that!
I have a problem that I dont have my head into yet and hoping you all can help me.
Need to use batch file commands here and I need insert a line of text and then later remove that line depending on what the operator wants.
Code showing sample of the text file.The line in question appears most of the time on line 4 of the code (TIMECONSTANT 1), but not always. Any ideas here would be greatly appreciated and thanks in advance!
Have learned a lot here and thanks for that!
I have a problem that I dont have my head into yet and hoping you all can help me.
Need to use batch file commands here and I need insert a line of text and then later remove that line depending on what the operator wants.
Code showing sample of the text file.
Code: Select all
[MAIN]
MAP Netmountains/load.ini
TIME 12.0
TIMECONSTANT 1
CloudType 0
CloudHeight 1500.0
.......
.......
can be 200 lines at least