Batch IF ELSE statement both execute -


the batch file execute both commands in if , else. checked syntax , space, no idea wrong.

if exist c:\program files (x86)\google\chrome (     start chrome www.google.com ) else (     start iexplore www.google.com ) 

both chrome , ie opened if statement not working.

the space in path passed exist test confusing parser. in general should place quotes around such names.

if exist "c:\program files (x86)\google\chrome" (  start chrome www.google.com ) else (  start iexplore www.google.com  ) 

Comments

Popular posts from this blog

routing - AngularJS State management ->load multiple states in one page -

python - GRASS parser() error -

post - imageshack API cURL -