Logo 
Search:

MS Office Forum

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds

error trapping questions

  Asked By: Donna    Date: Aug 09    Category: MS Office    Views: 528
  

I have two questions for error trapping:

1. How can I determine the state of a userform in VBA? I need to know if a
userform is hidden or unloaded. I want to unload it in an error trapping routine
in case it is hidden, so that it is initialized with the start values again
after the error is correctly handled. If the userform is already unloaded, no
action is necessary.

2. I program in modules, meaning I use small procedures for the same tasks in
different modules. A subroutine may be called by many different procedures.
Additionally, such procedure may call another one, which again may call another
one. Is there a VBA command which tells me the name of the calling subroutine
and the "mother module" (meaning the very first macro)? I need this to terminate
the "mother" routine instantly in my error trapping, without going up all the
levels again and terminate each routine individually. I know I could store the
macro name in a variable, but this is not practicable.

Share: 

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on error trapping questions Or get search suggestion and latest updates.




Tagged: