Call Stack information

J

Jerry Kogan

Is there any way to get the same information you see when
you view the Call Stack from within VBA? Is there a
collection of opened procedures? I see there is a modules
collection, but how can you tell if a particular function
within a module is running?
 
D

Dev Ashish

how can you tell if a particular function
within a module is running?

As Sandra mentioned, there's no built in way for doing this. However, if
you have VBA Developers Handbook (Ken Getz and Mike Gilbert), it contains
couple of classes (ProcStack and ProcStackItem) that allow you to maintain
your own code based stack. So on enter and exit of each proc, you push and
pop items yourself.

Sub Foo
pStack.Push "Foo"
...
pStack.Pop
end Sub

-- Dev
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top