I convereted a macro to VBA, how do I point a control to the code

G

Guest

I convereted a macro to VBA, but now I just have the original macro and a new
module name "convereted macro-blahblah". I have a control whose event
procedure "on click" is still looking at the the macro. How do I tell the
control to look at the new converted macro-module so I can remove the macros?
 
D

Douglas J. Steele

Change what's in the On Click event for the form to [Event Procedure]
(select it from the pull-down list), then click on the ellipsis to the right
(...). That will take you into the VB Editor, inside the actual code for
that event. You can either copy-and-paste the converted code into that
procedure (do not copy the Sub or End Sub from the converted macro!), or you
can simply call your converted macro from that event.
 

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

Top