|Thanks alot for the help but my problem is i want to add the code in between commands not to add it below..|
to try it w/o "for/f" i used ur example bit modified..i saved the following under modify.bat
type userVar.bat | find /V /I "%strVar%=" >userVar.txt
echo set %strVar%=%intNum% >> userVar.txt
ren userVar.txt userVar.bat
then i execute the command "modify userVar1 400" but the userVar.bat file was like:
the command didn't add in to the prefered location ( i need to add it after "set userVar2=300") i think i would need to use for/f to locate that but i hav no idea how to use it...