Calling an event on main form from a subform

  • Thread starter Thread starter arm
  • Start date Start date
A

arm

Hi! Could anyone please help me how to call an event on main form from a
subform. Thanks.
 
Remove the word "Private" from the event procedure you wish to call. For
example change:
Private Sub Button1_Click()
to:
Sub Button1_Click()

Then from the subform:
Call Me.Parent.Button1_Click


Another alternative, assuming the main form is named "Form1":
Call Form_Form1.Button1_Click
 
Back
Top