Wednesday, November 11, 2009

Find and Replace in .txt file

Find and Replace in .txt file

It is magical that we can find and replace any text or any chr values in .txt file without opening it in notepad.

It's major requirement is a file named change.com which creates easy to do it. It is a DOS (disk operating system) command. It works as under :-

In Windows 98/ xp / vista etc.
1) Start>Run>cmd
2) Type c: and then cd \ press enter
3) Place change.com file here after download it from here.
4) Place any file.txt file in which you want to change text.
5) Command to change in file.txt is as under
change file.txt "old string " "new string"
change file.txt "old text" "new text"
change file.txt 26 ""
change file.txt 13,14 ""

Note :- in above examples 26 is chr value which will be converted in blank in file.txt under third example.

Click here to Download change.com here

No comments:

Post a Comment