title: CMD/windows Batch: how to pass a double quote and a larger than sign in a command argument?
body: <p>I can pass a double quote, and a larger than sign to any command in several ways: <code>'"'</code>, <code>"\""</code>, <code>"&gt;"</code></p>
  
  <p>But when i try to pass them together</p>
  
  <pre><code>C:\&gt;echo "\"&gt;"
  The system cannot find the path specified.
  </code></pre>
  
  <p>Same with <code>"\"\&gt;"</code>. I could make it work with single quotes around, but since i already have so much going on with dealing with quotes i'd like to keep it all inside double quotes.</p>
  
  <p>Is there any way to escape that?</p>
  
  <p>I'm on windows7 but i believe this is some backward compatibility 'feature', so not sure this info is relevant.</p>
  
  <p>Edit 1:</p>
  
  <p>I tought Endoro had the right answer... but it's not that simple. CMD treats <code>^&gt;</code> differently depending if there's a escaped double quote in the string. Anyone have any idea why?! or a different escaping method?</p>
  
  <pre><code>C:\&gt;sh echo "\"^&gt;"
  "&gt;
  
  C:\&gt;sh echo "a^&gt;"
  a^&gt;
  
  C:\&gt;echo "\"^&gt;"
  "\"&gt;"
  
  C:\&gt;echo "a^&gt;"
  "a^&gt;"
  </code></pre>
  
  <p>Edit 2:
  here are the tests cases for what Monacraft suggested, using <code>^</code> before the quotes that go around the string</p>
  
  <pre><code>C:\&gt;echo ^"a/&gt;"
  The system cannot find the path specified.
  (we still need to escape that &gt; symbol)
  
  C:\&gt;echo ^"a/^&gt;"
  "a/&gt;"
  (work fine without \" in the string)
  
  C:\&gt;echo ^"\"/^&gt;"
  "\"/^&gt;"
  (add a single \" and the ^&gt; escaping stop to works)
  
  C:\&gt;echo ^""/^&gt;"
  ""/^&gt;"
  (ok, using ^ before the string means i dont have to escape the " anymore)
  
  C:\&gt;echo ^"^\"/^&gt;"
  "\"/^&gt;"
  (but what if i have an actual \" in my input that i have to escape... would ^\ prevent this from happening? nope)
  </code></pre>