title: Invalid syntax with "setx" for having more than two arguments when there are only two arguments
body: <p>I'm having trouble setting the global environment variable <code>PATH</code> permanently with <code>SETX</code>.</p>
  
  <p>I've read the answers on similar questions such as <a href="https://stackoverflow.com/a/17215799/2886326">Invalid syntax with setx</a> as well as read the syntax on <a href="http://ss64.com/nt/setx.html" rel="noreferrer">SS64</a>. </p>
  
  <p>As far as I know, the following line follows the syntax of <code>SETX</code> correctly and does <strong>NOT</strong> have more than two arguments in it:</p>
  
  <pre><code>SETX PATH "%PATH%"
  </code></pre>
  
  <p>But that doesn't stop <code>SETX</code> from giving me this error:</p>
  
  <pre><code>ERROR: Invalid syntax. Default option is not allowed more than '2' time(s).
  Type "SETX /?" for usage.
  </code></pre>
  
  <p>The above command was <strong>run on an administrator instance of <code>cmd.exe</code></strong>. What makes the problem all the more stranger is that <strong>on a user instance of <code>cmd.exe</code> the same command works perfectly.</strong></p>
  
  <p>I simplified the above command to emphasize the problem, but what I'm really trying to run is:</p>
  
  <pre><code>SETX PATH "%PATH%;D:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin" /M
  </code></pre>
  
  <p>Of course, this gives the same exact error, and I can't run it on a user instance of <code>cmd.exe</code> because I'm trying to set the global environment variable <code>PATH</code> permenantly. (which needs administrator access)</p>