Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Determine which button was clicked on a sheet
Hi XP,
Try something like: '============= Public Sub Tester() MsgBox Application.Caller End Sub '<<============= --- Regards, Norman "XP" wrote in message ... I have several regular buttons (i.e. not an activeX button) control on a sheet. All of these buttons run the same user form, but I want the results placed into separate cells depending upon which button was clicked to load the form. Using VBA, can someone please post example code that determines which button was clicked on the sheet, using the button's caption as the defining variable? Thanks in advance. |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Determine which button was clicked on a sheet
Hi XP,
Just to add, having assigned this macro to each button of interest, clicking the button will return a message comprising the button's name. --- Regards, Norman "Norman Jones" wrote in message ... Hi XP, Try something like: '============= Public Sub Tester() MsgBox Application.Caller End Sub '<<============= --- Regards, Norman "XP" wrote in message ... I have several regular buttons (i.e. not an activeX button) control on a sheet. All of these buttons run the same user form, but I want the results placed into separate cells depending upon which button was clicked to load the form. Using VBA, can someone please post example code that determines which button was clicked on the sheet, using the button's caption as the defining variable? Thanks in advance. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Determine when checkbox is clicked | Excel Discussion (Misc queries) | |||
Determine last clicked object / control | Excel Programming | |||
Pause macro, add form button to sheet, continue macro when button clicked! | Excel Programming | |||
How to determine which dynamically generated control was clicked | Excel Programming | |||
How to determine which button was clicked on the modified right-click menu | Excel Programming |