747skipper
New member
- Local time
 - Today, 08:31
 
- Joined
 - Sep 30, 2019
 
- Messages
 - 16
 
OK a bit of a weird request, but does anyone know if I can obtain the name of the current sub or function at run time, in code?
I have a top level error handler to close a form and return to menu, acting as a back stop if an error I haven't allowed for occurs.
This covers several subs and functions and it would be really useful to know which one triggered it. (think line numbers in pre history)
I could declare a global variable and set it in each sub but I wondered if there is an easier way?
Thanks
 I have a top level error handler to close a form and return to menu, acting as a back stop if an error I haven't allowed for occurs.
This covers several subs and functions and it would be really useful to know which one triggered it. (think line numbers in pre history)
I could declare a global variable and set it in each sub but I wondered if there is an easier way?
Thanks