View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
GS[_2_] GS[_2_] is offline
external usenet poster
 
Posts: 3,514
Default Reference must be to a macro sheet?

I made a few copies of Sheet1 by right-clicking the tab and
choosing "Move or Copy", followed by "Create a copy".

Next, I added one one Button control on each sheet.
When I try to assign an existing sub procedure to some
of the buttons I get the following error message:

"Reference must be to a macro sheet"

Does anybody know why this error message is
occurring and how to fix it?

Thanks!


Assigned macros should be stored in a standard module, IMO.
Button_Click event code should be stored in the code window of the
sheet the button resides on.

--
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion