Reputation: 3974
I am currently working with an application not written by me but by one of my colleagues that resigned more than a year ago. He did not use any comments in his code, nor left any workflows, notes or anything to document the flow of an application.
I have access to use one of the classes he has created, and within the class is a method which I need to reuse in my current application. I spent more than an hour trying to find out where he has referenced this method call, but for the life of me, I cannot seem to find it. I have seen that this method in his application does run, and it works just fine.
Is there any way I can trace all method calls from the start of the application up till the breakpoint I have inserted in this method in Visual Studio 2010? I never had a need to do this up till now.
Update
This is an ASP.NET MVC2 application. I have looked through all the views and controllers, used the search function set to entire solution, with case sensitivity off. I'm pretty sure code does not just run spontaneously :).
Upvotes: 2
Views: 2743
Reputation: 39370
From the last edit, I guess that Find all references
button would suit your needs.
Unfortunately, you can't set breakpoint on the function declaration; however, if you set a breakpoint in a function body, you can then use Call Stack
to find out where it was called.
If you still can't find it with it, i suggest you double-check your standard search function.
Upvotes: 2