Jaafar Tribak
Well-known Member
- Joined
- Dec 5, 2002
- Messages
- 9,621
- Office Version
- 2016
- Platform
- Windows
Hi Experts,
I have 40 CommandButtons embeeded on a worksheet.
I want to assign a generic On Click Event procedure to all these Buttons via a class Module so that when any of the Buttons is Clicked ,a MsgBox pops up with the name of the Button displayed.
This can easily be done with CommandButtons on a UserForm using the above technic with no problems.
It is also possible to achieve the same effect with Worksheet Buttons from the Forms Toolbar thanks to the OnAction and Application Caller properties.
However, I can't seem to make any of the above aproaches work when it comes to embeeded worksheet OLEobjects such as CommandButtons from the Control ToolBar.
I am very curious to know if this is possible.
Any Ideas ? ray:
TIA.
I have 40 CommandButtons embeeded on a worksheet.
I want to assign a generic On Click Event procedure to all these Buttons via a class Module so that when any of the Buttons is Clicked ,a MsgBox pops up with the name of the Button displayed.
This can easily be done with CommandButtons on a UserForm using the above technic with no problems.
It is also possible to achieve the same effect with Worksheet Buttons from the Forms Toolbar thanks to the OnAction and Application Caller properties.
However, I can't seem to make any of the above aproaches work when it comes to embeeded worksheet OLEobjects such as CommandButtons from the Control ToolBar.
I am very curious to know if this is possible.
Any Ideas ? ray:
TIA.