Getting sub name as parameter

D

dhstein

I want to write a function that will log some types of unexpected database
conditions (e.g. a Dlookup returns a null value). One of the arguments will
be the name of the subroutine that's calling the function so I can track down
where the condition occurred. Instead of hard-coding the name, is there a
way of getting the name of the subroutine in VBA ? Thanks for any help on
this.
 
S

Stefan Hoffmann

hi,
I want to write a function that will log some types of unexpected database
conditions (e.g. a Dlookup returns a null value). One of the arguments will
be the name of the subroutine that's calling the function so I can track down
where the condition occurred. Instead of hard-coding the name, is there a
way of getting the name of the subroutine in VBA ?
No, it's not possible.

You may use a tool like mztools.com which can provide method templates,
this will at least reduce the amount of code to type.


mfG
--> stefan <--
 
Top