I see the same message. This can happen if you do this:
System.Diagnostics.Process proc = new System.Diagnostics.Process(); proc.StartInfo.FileName = "trash filename here.exe"; try { proc.Start(); } catch { }//proc should fail. try { if (proc.HasExited) { //.... } } catch (System.InvalidOperationException e) { //cry and weep about it here. }
If proc.Start() failed above, you also need to cry and cry. So, if you catch proc.Start() , be sure to catch in proc.HasExited (and proc.HasExited other System.Diagnostics.Process methods.
source share