title: How to find out that a process started Ok
body: <p><br>
  I am trying to find out if there is a good way to know if a <code>Process</code> is started correctly.<br>
  I use the following code :</p>
  
  <pre><code>        if (!_process.Start())
          {
              throw new Exception("Component {0} failed to start.".FormatWith(component.Name));
          }
  
          if (!_process.IsMyProcessRunning())
          {
              throw new Exception("Component {0} failed to start.".FormatWith(component.Name));
          }
  
  static public class MyExtensions
  {
      public static bool IsMyProcessRunning(this Process process)
      {
          return !process.HasExited &amp;&amp; process.Id != 0 ;
      }
  }
  </code></pre>
  
  <p>i guess that the <code>Start()</code> method is faster and sometimes i get the exception and sometimes no. my process is starting a faulted program.</p>