How to debug a single thread in Visual Studio?

I have a solution with some projects. There are several break-points in different projects. I want to trace the first thread hit one of these break-points and continue tracing that single thread despite of other threads entering the same code-blocks.

I know this is possible through defining a condition on the break-point, that is, thread name = … or thread Id = … but my case is a heavy loaded ASP.NET application and as soon as I attach to w3wp.exe many threads will hit the break-points. I need some thing like a ThreadLocal<break-point>.

Is it possible? If so, how?

10 Answers
10

Leave a Comment