title: Double-Quotes in start line of Windows Batch script
body: <p>I have looked at the answers already provided, but I'm still stuck. Here is what I currently have:</p>
  
  <pre><code> start "" "C:\Program Files (x86)\Spark\Spark.exe"
   echo Spark started
  </code></pre>
  
  <p>This works fine. But now I want to pass parameters to the client, which must be wrapped in quotes. I can do the following on the command line:</p>
  
  <pre><code> "C:\Program Files (x86)\Spark\Spark.exe" "user=%USERNAME%&amp;server=example.org"
  </code></pre>
  
  <p>And it starts up with the user and server fields filled in.</p>
  
  <p>But when I try to edit the batch script to add those quote-wrapped parameters, I get a variety of errors depending on how I try to add double-quotes and where, etc.</p>
  
  <p>So how would I add a quote-wrapped parameter to the start line?</p>
  
  <h2>Update:</h2>
  
  <p>I accidentally got it to work, but haven't been able to reproduce it. But it didn't work exactly right. The user name was still blank, but the server was filled in. I forgot to mention that I am using an environment variable for the user name:  <code>%USERNAME%</code></p>
  
  <p>So it might be my problem is that I can't escape quotes and use environment variables?</p>
  
  <h2>Final Answer:</h2>
  
  <p>It turns out that part of the problem was that I was using the wrong parameter, but originally I had been using the right one, so I didn't notice. From the command line, I should have:</p>
  
  <pre><code> "C:\Program Files (x86)\Spark\Spark.exe" "username=%USERNAME%&amp;server=example.org"
  </code></pre>
  
  <p>and so from the batch file, the following works:</p>
  
  <pre><code> start "" "C:\Program Files (x86)\Spark\Spark.exe" "username=%USERNAME%&amp;server=example.org"
   echo Spark started
  </code></pre>
  
  <p>Much thanks and points to dcp for getting me to the right answer.</p>