title: How to execute Process commands (or similar) using a Universal Windows Platform (UWP) App?
body: <p>I'm working on creating custom Cortana commands. The commands are registered and executed using a Universal Windows Platform Application. <a href="https://github.com/crclayton/custom-cortana-commands-template">(GitHub)</a></p>
  
  <p>For instance, I've registered the following command</p>
  
  <pre><code>&lt;Command Name="ShutDown"&gt;      
    &lt;ListenFor&gt;Shut down&lt;/ListenFor&gt;
    &lt;Navigate/&gt;    
  &lt;/Command&gt;
  </code></pre>
  
  <p>To run this function in a UWP application</p>
  
  <pre><code>static async void ShutDown()
  {
      var dialog = new MessageDialog("This is where I would shut the computer down.");
      await dialog.ShowAsync();
      //System.Diagnostics.Process.Start("Shutdown", "-s -t 10");
  }
  </code></pre>
  
  <p>But after setting this up I learned <code>System.Diagnostics.Process</code> isn't supported in UWP. </p>
  
  <p>The custom commands I want to run involve some sort of execution such as launching external programs, running other scripts, or opening websites. </p>
  
  <p>It makes sense that UWP doesn't support them given that it's universal and an XBox or a phone might not be able to do these, but I was hoping there was some alternative or hacky way to accomplish this on a Windows 10 PC.</p>
  
  <p>Is there a way for me to execute <code>Process</code> commands or something else with similar functionality in a UWP application? It seems like even though I can get Cortana to execute my C# code, UWP doesn't support much that would be useful in this situation.</p>
  
  <p>Thanks in advance.</p>