batch file - Read / Echo Environmental Variable as Literal -


very basic, or thought. i've got string in command prompt:

c:\>echo "start c:\users\%username%\my documents" >> test.txt 

i've tried %%username%%, '%username%', '%'username'%', , many other ways. batch output resolves environmental variable rather writing literal string of text. possible make sure reads literal string of text , not environment variable resolves to?

echo start ^"^" ^"c:\users\^%username^%\my documents^" >> test.txt 

this should work.


Comments

Popular posts from this blog

iphone - Three second countdown in cocos2d -

hyperlink - how to do url routing in php -

c++ - CryptStringToBinary API behavior -