title: Run cmd or exe file from asp.net page
body: <p>I have problem with running cmd or exe file from asp.net page.</p>
  
  <p>I used this code:</p>
  
  <pre><code>protected void btnRun_OnClick(object sender, EventArgs e)
  {
    var p = new Process();
    var info = new ProcessStartInfo
                              {
                                FileName = Server.MapPath("~/print.cmd"),
                                UseShellExecute = false,
                                WindowStyle = ProcessWindowStyle.Hidden,
                              };
    p.StartInfo = info;
    p.Start();
    p.WaitForExit();
  }
  </code></pre>
  
  <p>When I run my web application on VS Development Server everything is ok,
  but when I deploy this code on IIS (ver 7.5), the code working without errors but 
  nothing happens.</p>
  
  <ul>
  <li>I used search on google and SO, but I didn't find any solution</li>
  <li>I tried <a href="http://support.microsoft.com/kb/555134" rel="nofollow">http://support.microsoft.com/kb/555134</a> and <a href="http://support.microsoft.com/default.aspx?scid=kb;en-us;317012" rel="nofollow">http://support.microsoft.com/default.aspx?scid=kb;en-us;317012</a></li>
  <li>I set 'Allow service to interact with desctop' for IIS Admin service.</li>
  <li>I played with user rights but this didn't give me any results.</li>
  <li>I changed Identity for Application Pools</li>
  </ul>
  
  <p>is it possible to run cmd or exe with IIS? </p>