title: PowerShell script ONLY runs from within PowerShell, not as an argument to powershell.exe
body: <p>Quite simply:</p>
  
  <pre><code>&gt; powershell.exe -command "&amp; '\\RemoteServer\c$\My Script.ps1'"
  </code></pre>
  
  <p>does not work at all.  <code>My Script.ps1</code> opens in Notepad, nothing more.  Meanwhile,</p>
  
  <pre><code>&gt; powershell
  PS &gt; &amp;"\\RemoteServer\c$\My Script.ps1"
  </code></pre>
  
  <p>works just fine (the script executes).</p>
  
  <p>I did have to use the <code>caspol</code> tool, since my script relies on a binary module, but I don't see how that could be the issue.</p>
  
  <p>Any thoughts as to the cause of this issue?</p>
  
  <p>Thanks!</p>