Tech
Forums
Jobs
Books
Events
Videos
Conference
Annual Conference
Bcrypt
Ai Conference
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
6
Reply
Control array with 1 DoubleClick event handler, how to determine which control initiated event?
Ask a question
Ask a question
Upload Source Code:
Select only zip and rar file.
Ramon Liverance
14y
3.5k
1
Reply
I have a screen with an array of labels (coded as: label[] aLabel = new label[30];
I would like to write a single DoubleClick event that handles all Double Click events for the array but action taken would be unique for the aLabel[] clicked. Therefore I have to determine which aLabel was DoubleClicked - there in lies the problem. There seems to be no way of determining the index value of the aLabel initiating the event. the sender data (in the event handler) can be viewed when in debug mode in VS2008 but there is no way of access this data withou knowning which indexed aLabel was clicked.
Any ideas??? this is driving me crazy and I'd hate to have to create 31 event handles, one for each indexed aLabel.
Post
Reset
Cancel
Answers (
6
)
Next Recommended Forum
Searching columns in datagridview
project hotel reservation system source code