vb6 tracking where a function was called from
I recently inherited a VB6 project. It is pretty involved and my issue is that many different functions call this centralized function. Meaning when I do a find I get a ton of different locations in the project that make this call. Is there a way to see in debug mode what function called the function I have a break point on?
For example: funcA calls funcZ funcB calls funcZ funcC calls funcZ it goes on and on...
If I put a break point on funcZ is there anyway in VB6 that I can see what functi开发者_运维知识库on called funcZ (A,B or C in my example)?
Just wondering...
Yes. Hit Ctrl+L to see the call stack.
A nice free tool (every VB6 IDE should have it) that amongst its many cool features is one that shows all calling procedures for any sub or function.
http://www.mztools.com/v3/download.aspx
What you seem to be asking about is a stack trace. Memory fails how easy/hard this is so a quick google search brought up this question. Combine that with some output to the immediate window, and you should be good.
Edit: Wim's answer is much better.
精彩评论