title: Avoid "program stopped working" in C#/.NET
body: <p>I have a console application written in C#/.NET that I want to run from a script (nant). If an exception occurs in the console application, I would like nant to continue, but in Windows Vista there is a popup that searches for solutions and asks for debug etc.</p>
  
  <p>I would like to avoid the popup with "program stopped working" when an exception happens in the console application. How can I control this from C#/.NET?</p>
  
  <p>(A similar question addresses <a href="https://stackoverflow.com/questions/312300/catch-the-program-stopped-working-on-vista">the issue for the C language</a>, but I would like a solution for C#/.NET.)</p>
  
  <p>(To clarify: I would like the exception to be passed to nant, but <em>without</em> the popup.)</p>