title: Batch script: Problems with SET in an IF
body: <p>The problem is that my <code>set tap=c:\ca\sf\1st 2nd...</code> etc. isn't working at all.
  The <code>echo</code> shows nothing, the <code>set</code> isn't putting the path in the variable for some reason.
  I got all <code>if</code>s right, is there another problem?</p>
  
  <pre><code>setlocal enabledelayedexpansion  
  
      if NEWYORK == %region% (  
          set tap=C:\ny  
          CALL :process %1 %2 %tap% %cl%  
          GOTO :EOF  
      )  
      if California == %region% (  
          if '%3'=='sanfrancisco' (  
              set cl=c:\ca\sf\cl  
              if '%2'=='1st' set tap=c:\ca\sf\1st  
              if '%2'=='2nd' set tap=c:\ca\sf\2nd  
              if '%2'=='3rd' set tap=c:\ca\sf\3rd  
              if '%2'=='4th' set tap=c:\ca\sf\4th  
              if '%2'=='5th' set tap=c:\ca\sf\5th  
              echo %tap%, echo %cl%,  
              pause  
              CALL :process %1 %2 %tap% %cl%  
              GOTO :EOF  
          )  
          if '%3' == 'LosAngeles' (  
              set tap=c:\ca\la  
              set cl=c:\ca\la\cl  
              echo %tap%, %cl%  
              pause  
              CALL :process %1 %2 %tap% %cl%  
              GOTO :EOF  
          )  
          set tap=c:\USA  
          set cl=c:\usa\cl  
          echo %tap%, %cl%  
          pause  
          CALL :process %1 %2 %tap% %cl%  
          GOTO :EOF ) else (  
          echo faiiiiiiiiiillllllllll  
          pause  
          GOTO :END)  
      endlocal  
      GOTO :EOF  
  </code></pre>