A batch file conundrum -


i using windows xp.trying create batch file work location in response user input.it works fine except glitch.if user inputs

c:\documents , settings\username\desktop\file.txt 

the following batch works fine:

set /p x= file ?   set /p =number: <nul   find /v /c "" <%1 %x%> linecount.txt msg %username%<linecount.txt || start linecount.txt  del linecount.txt.  

but if assume user computer saavy , use path

%userprofile%\desktop\file.txt 

with or without quotes batch file fails message system cannot find path!. @ wits end.

i might wrong think % has after %userprofile.

in case be:

%userprofile%\desktop\file.txt


Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

jquery - javascript onscroll fade same class but with different div -