I am working in Excel. I have a button that lanches a form. What function is called as soon as the form initiates? I need the form to call a function as soon as the form is drawn.
thank you
Printable View
I am working in Excel. I have a button that lanches a form. What function is called as soon as the form initiates? I need the form to call a function as soon as the form is drawn.
thank you
You get these two events in this order.
The initialize fires first. Then when its shown either from being initialized or restored from a mimimized stateVB Code:
Private Sub UserForm_Initialize() End Sub Private Sub UserForm_Activate() End Sub
or another app had the focus and then the userform gets focus, the Activate event fires.