title: How do I return a value from a console application to a service in .NET?
body: <p>I have a .NET service.</p>
  
  <p>I have a .NET console application.</p>
  
  <p>I want something along the lines of the service calling <code>Process.Start("consoleapp.exe")</code> and getting some information returned back from the app, ideally just returning a number.</p>
  
  <p>How do I do this?</p>
  
  <p><b>Edit:</b></p>
  
  <p>I figure it must be: <code>Process.Start("myapp.exe").ExitCode</code> - but how do I set the exit code in the console app?</p>