title: PsExec to Remotely run a GUI Application
body: <p>I am trying to launch a GUI application remotely using PsExec.</p>
  
  <pre><code>            ProcessStartInfo info = new ProcessStartInfo(@"&lt;path to dir&gt;");
              info.FileName = @"C:\&lt;dirpath&gt;\PsExec.exe";
              info.Arguments = @"\\" + "&lt;COmputerName&gt;" + " " + @"""C:\Program Files (x86)\&lt;exepath&gt;\&lt;exename&gt;.exe""";
              info.RedirectStandardOutput = true;
              info.UseShellExecute = false;
              info.RedirectStandardError = true;
              info.WindowStyle = ProcessWindowStyle.Maximized;
  
              Process o = Process.Start(info);
  </code></pre>
  
  <p>The issue here is that the process does launch remotely, but I cannot see the GUI. I can only see it in task manager.
  Is there a way to see the <em>GUI</em> on the remote computer?</p>
  
  <p>EDIT 1:
  <strong>*<em>Permissions</em>*</strong></p>
  
  <ol>
      <li>            Console.WriteLine (System.Environment.UserName.ToString());</li>
  <li>                Console.WriteLine(Thread.CurrentPrincipal.Identity.Name.ToString());</li>
  <li>                Console.WriteLine ("current winddentity " + System.Security.Principal.WindowsIdentity.GetCurrent().Name.ToString());</li>
  </ol>
  
  <p>If I execute above lines of code before starting process, it gives:
  
  <li>administrator</li>
  <li><em>blank</em></li>
  <li><em>DomainName</em>\administrator</li>
  and I am logged it with the administrator account on the remote computer as well.</p>
  
  <p>*<strong><em>InteractiveMode</em>*</strong>
  When I try to use the switch -i from the cmd prompt it gives:
  Process exited with error code -1073741502.
  While trying to execute using C#, it doesnt do anything at all. No exception at least!</p>
  
  <p>END OF EDIT 1.</p>