title: Batch File - Syntax Incorrect (Going inside a directory)
body: <p>I am writing a batch script to go inside a folder  if it exists do a certain thing if its not do other</p>
  
  <p>I have the hierarchy as follows :-</p>
  
  <pre><code>  C:\Validation\docs\chm\help.chw
  </code></pre>
  
  <p>I want to go to this 'help.chw' file this is what i am doing and getting the error</p>
  
  <pre><code>IF EXIST docs (
  CD docs echo curr dir = %CD% goto imagefolder 
  ) 
  
  IF EXIST docs (
  CD docs echo curr dir = %CD% goto imagefolder 
  ) 
  
  ECHO Please include 'docs' folder in the current working directory
  ECHO.
  ECHO The program would close now , restart the batch file after making the changes cited above
  ECHO.
  goto exit
  </code></pre>
  
  <p>This is what i wrote</p>
  
  <pre><code> IF EXIST docs (
   CD "docs"
   echo curr dir = %CD%
   goto imagefolder
  </code></pre>
  
  <p>)</p>
  
  <p>it gives    </p>
  
  <pre><code> C:\Validation MSI
  </code></pre>