title: Use the Visual Studio command prompt with WiX in a build event
body: <p>I've been trying to sign an <a href="http://en.wikipedia.org/wiki/Windows_Installer" rel="nofollow">MSI</a> file in a post build event with the following code</p>
  
  <pre><code>signtool sign /t http://timestamp.verisign.com/scripts/timestamp.dll /f "E:\Products\Tools\DigitalId\Certificate.pfx" /p 1501ocbc /d "Server" "E:\Products\Setup\Server_Setup\ServerSetup\bin\Release\en-US\ServerSetup.msi"
  </code></pre>
  
  <p>This will sign OK with the Visual Studio command prompt and similar code works for C++ projects. However, when building the setup and signing the code with post build events, I get a code error, 9009. After much debugging I have come to the conclusion that WiX is using the ordinary command prompt. How do I get <code>cmd.exe</code> in WiX to open with Visual Studio tools?</p>
  
  <p>Or is there another way to sign my packages?</p>