Search found 5 matches

by 이용민
17 Mar 2012 14:12
Forum: DOS Batch Forum
Topic: [HELP] Writing To File
Replies: 7
Views: 4574

Re: [HELP] Writing To File

Yeah, I just figured that out now :)

Thank you for all your help. It is greatly appreciated.
by 이용민
17 Mar 2012 14:06
Forum: DOS Batch Forum
Topic: [HELP] Writing To File
Replies: 7
Views: 4574

Re: [HELP] Writing To File

Thank you, and what method would I use to prepend more than 1 line?

Code: Select all

for /f "delims=" %%a in ('dir/b *.cfg') do >>"%%a" echo(Test=0 echo(Test2=0


????
by 이용민
17 Mar 2012 13:52
Forum: DOS Batch Forum
Topic: [HELP] Writing To File
Replies: 7
Views: 4574

Re: [HELP] Writing To File

Ok, it now seems to work fine (even with spaces) from using the code you posted above, but now I have a question on how to make it add it to the 'end' of the file. It is currently adding the text to the top of the file, and I want it added to the bottom.
by 이용민
17 Mar 2012 13:46
Forum: DOS Batch Forum
Topic: [HELP] Writing To File
Replies: 7
Views: 4574

Re: [HELP] Writing To File

Basically, I have a folder that contains X amount of CFG files. Some of the file names don't have spaces, some do have spaces. When I run the bat, it works correctly by prepending the line Test=0 into the files that don't have spaces, but it does not prepend the Test=0 line with the files that have ...
by 이용민
17 Mar 2012 13:27
Forum: DOS Batch Forum
Topic: [HELP] Writing To File
Replies: 7
Views: 4574

[HELP] Writing To File

What I want to do is basically write information to X amount of files at the same time. I have a script that is working at the moment, but it misses out the files that have spaces in their name. If anyone can help me, it'd be greatly appreciated. Here is the script: @echo off & setLocal EnableDE...