LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Event Handlers: Getting a handle to the calling object

Hello,
Building something in Excel using VBA.
Is there a way to access the element that fired the event within the event
handler?

for example:
Sub ComboBox1_Click()
'Currently I am doing the following
ComboBox1.doSomething(bla,bla)

'Am I doomed to have to get at this object by name, and hence have to
change
'the event handler code of all the different combo boxes in the
'sheet in order to match their name?
'Ideally there would be a "this" keyword to use, but I don't think VBA
has that.
'Any other way

End Sub


Thanks so much
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help with adding Controls and event handlers at runtime [email protected] Excel Programming 0 December 27th 06 04:36 PM
Need help with adding Controls and event handlers at runtime [email protected] Excel Programming 0 December 27th 06 04:36 PM
Further Clarification with Event Handlers & Class Modules Kevin H. Stecyk[_2_] Excel Programming 2 January 25th 05 05:10 PM
Grouping Event handlers Ripan[_4_] Excel Programming 4 February 7th 04 02:40 PM
Problems with event handlers Italian Job Excel Programming 2 November 12th 03 01:26 AM


All times are GMT +1. The time now is 12:26 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"