|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Multiple Handles clause: which control fired the event?I have one control DoubleClick event that handles the DoubleClick events for
multiple controls. The .Tag property contains a different string value in each control that I would like to examine. How can I get the .Tag property value no matter which control was double clicked? Reflection? Thanks, Dean S "Dean Slindee" <slin***@charter.net> wrote in You can retrieve the original control via the "Sender" parameter.news:WUt5h.191$Dg6.47@newsfe02.lga: > I have one control DoubleClick event that handles the DoubleClick > events for multiple controls. The .Tag property contains a different > string value in each control that I would like to examine. How can I > get the .Tag property value no matter which control was double > clicked? Reflection? Dean Slindee wrote:
> I have one control DoubleClick event that handles the DoubleClick events for You don't need reflection, you can just cast the sender paramter to> multiple controls. The .Tag property contains a different string value in > each control that I would like to examine. How can I get the .Tag property > value no matter which control was double clicked? Reflection? > > Thanks, > Dean S control, and then you will have access to the Tag property: Private Sub DoubleClick (ByVal sender As Object, ByVal e As EventArgs) Dim ctrl As Control = DirectCast (sender, Control) Dim stringValue As String = DirectCast (ctrl.Tag, String) ' Do stuff with stringValue End Sub
"how to split a string in a random way"
Location for shared Access database Extract Single Record from Dataset filled from SP Output Creating text boxes on the fly? String manipulation question for each step order reverse direction ? single line string maninuplation substring, trim, indexof ? Installing .net assemblies windows installer About Access Windows Service information Shared database without network tech required |
|||||||||||||||||||||||