Did you know… You can debug an executable that isn’t a part of a Visual Studio project without using Tools – Attach to Process? - #296
And yet another, “I would have never thought to do that” feature in Visual Studio.
There’s the standard Tools – Attach to Process dialog that allows you to attach and debug any process currently running on your machine. But if you’re trying to debug an issue that occurs at startup (meaning the application fails or crashes before you can attach to it) or if the application finishes too quickly before you can attach, there’s still a way to debug it.
Go to File – Open Project and give it the name of the executable. Yes, even thought it isn’t a “project” per se, like a .proj or .sln, the dialog will accept an executable.
Now you’ll see the executable opened in Solution Explorer as a project.
Just hit F5 as usual to start the executable.
Technorati Tags:
VS2005Tip,
VS2008Tip