Explained at http://stackoverflow.com/questions/9681863/windows-batch-variables-wont-set
The first -echo- does not display "myVar" value.
The second -echo- does.
Why??
Thanks for your time...
@echo off
set myVar=
if NOT DEFINED myVar (
set myVar=1
rem Variable substitution is not done here!
echo myVar = %myVar%
)
rem This one works OK...
echo myVar = %myVar%

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic