title: Is my process waiting for input?
body: <p>I am using the Process class to run an exe.</p>
  
  <p>The exe is a 3rd party console application that I do not control.</p>
  
  <p>I wish to know whether the process is waiting for input on the command line.</p>
  
  <p>Should it make any difference, I intend to kill the application should it be waiting for input.</p>
  
  <p>There are suitable events for when there is output from the program waiting to be read, but I cannot see anything similar for when the process is waiting patiently for input.</p>
  
  <pre><code>            ProcessStartInfo info = new ProcessStartInfo();
              info.FileName = "myapp.exe";
              info.CreateNoWindow = true;
              info.UseShellExecute = false;
              info.RedirectStandardError = true;
              info.RedirectStandardInput = true;
              info.RedirectStandardOutput = true;
              process.StartInfo = info;
  
              process.OutputDataReceived += new DataReceivedEventHandler(process_OutputDataReceived);
              process.ErrorDataReceived += new DataReceivedEventHandler(process_ErrorDataReceived);
  
              process.Start();
  
              process.BeginOutputReadLine();
              process.BeginErrorReadLine();
  
  
              process.WaitForExit();
  </code></pre>
  
  <p>How do I detect that my process is waiting for input?</p>