Find knowledge base article(s) by searching for keywords in the title e.g. type linux in the search box below
Find knowledge base article(s) by browsing the subject categories of articles
Technology quick references, cheatsheets, user manuals etc.
Shop Online through ShopifyLite
Tutorials on various IT applications.
Search Title    (UL:0 |SS:f)

Software >> OS >> Windows >> Command Line >> What is the difference in variable syntax for command line versus batch files


In batch files variables should be referred as %%variable
 
On command lines variables should be referred as %variable
 

For example, 


## On the command line

FOR /L %a in (1,1,254) DO @echo  172.31.5.%a
 

## In a batch file

FOR /L %%a in (1,1,254) DO @echo  172.31.5.%%a



[ © 2008-2021 myfaqbase.com - A property of WPDC Consulting ]