how to run macro in userform button

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

Guest

i have made a button (cmd1) on form (frm1)
i want to run a macro by clicking the button what should i do
regards
 
Open up the VBE and Double-Click on the button in question. This will take
you to the button's module with the Button_Click() event already selected.
Type or paste the code into this sub procedure.

I assume you know where the to go to access the VBE, but here are quick
direction just in case. Press Alt+F11 on your keyboard.

tj
 
Private Sub CommandButton1_Click()
myMacro
End Sub

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top