call an event button click from another form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a form (FormA) always open, visible or hide.
How can I call an event existing in the button of the FormA from another form?
Thanks for suggestions
jcp
 
First, the event procedure in the FormA form has to be declared public
Then, if it is a Sub

Forms!FormA.Button_Click

However; to avoid any confusion, I would suggest you put the code the button
executes in a standard module then just call it form both FormA and your
other form.
 
Back
Top