How can I attach the active debugger to a newly launched process?
For example, what goes in the if statement in the following code:
Process process = new Process();
process.StartInfo.FileName = path;
process.StartInfo.WorkingDirectory = Path.GetDirectoryName(path);
process.StartInfo.RedirectStandardInput = true;
process.StartInfo.RedirectStandardOutput = true;
process.StartInfo.UseShellExecute = false;
process.Start();
if (Debugger.IsAttached)
{
// How do I attach?
}
Thanks,
Sam
------------------------------------------------------------
We're hiring! B-Line Medical is seeking .NET
Developers for exciting positions in medical product
development in MD/DC. Work with a variety of technologies
in a relaxed team environment. See ads on Dice.com.
|