C:>type BatchSubstitute.txt
!!! THIS TEST DOESN`T REPLACE ANYTHING, IT JUST MAKES SURE
!!! THE SCRIPT WORKS FOR SPECIAL CHARACTERS.
!!! THE SCRIPT WOULD NOT WORK IF ANY OF THE CHARACTERs &<>|^ WOULD
!!! APPEAR WITHIN A QUOTED STRING
Next line is empty
this > is a grater-than character
this < is a less-than character
this ( is a opening bracket character
this ) is a closing bracket character
this % is a percent character
this & is an ampersand character
this ! is an exclamation character
this " is a quote character
this | is a vertical character
this ^ is a up character
this is a "quoted string"
this is a %percented string%
this is a !exclamationed string!
a "quoted ( opening bracket"
a "quoted ) closing bracket"
a "quoted % quote character"
a "quoted ! quote character"
a "quoted " quote character"
C:>BatchSubstitute.bat Oldtext Newtext BatchSubstitute.txt
!!! THIS TEST DOESN`T REPLACE ANYTHING, IT JUST MAKES SURE
!!! THE SCRIPT WORKS FOR SPECIAL CHARACTERS.
!!! THE SCRIPT WOULD NOT WORK IF ANY OF THE CHARACTERs &<>|^ WOULD
!!! APPEAR WITHIN A QUOTED STRING
Next line is empty
this > is a grater-than character
this < is a less-than character
this ( is a opening bracket character
this ) is a closing bracket character
this % is a percent character
this & is an ampersand character
this ! is an exclamation character
this " is a quote character
this | is a vertical character
this ^ is a up character
this is a "quoted string"
this is a %percented string%
this is a !exclamationed string!
a "quoted ( opening bracket"
a "quoted ) closing bracket"
a "quoted % quote character"
a "quoted ! quote character"
a "quoted " quote character"
|