Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Sub SameMacroForTwoDropDownBoxes()
- 'The following line of code will tell you
- ' in a message box which of the two
- ' drop-down boxes initiated the macro
- MsgBox Application.Caller
- End Sub
- Sub SameMacroForTwoDropDownBoxes()
- 'The following line of code will tell you
- ' in a message box which of the two
- ' drop-down boxes initiated the macro
- Select Case Application.Caller
- Case "Drop Down 1"
- MsgBox "The first drop-down box has been changed."
- Case "Drop Down 2"
- MsgBox "The second drop-down box has been changed."
- Case Else
- MsgBox "No idea where this was coming from..."
- End Select
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement