[RESOLVED] [2005]combination of handles (small question)
A little stupid question (i think) but is there a way to combine 2 combobox handles
example:
VB Code:
Private Sub combobox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles combobox1.Leave OR Handles combobox1.SelectedIndexChanged
greetz and thx,
freakyme :wave:
Re: [2005]combination of handles (small question)
VB Code:
Private Sub combobox1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles combobox1.Leave, combobox1.SelectedIndexChanged
Re: [2005]combination of handles (small question)
super thx for the reply
probleme solved ;) ;) ;)
Re: [RESOLVED] [2005]combination of handles (small question)
Note that one method can handle as many events as you like, providing the signature is the same for each event. That means that the argument lists must match. If you want to execute the same code on more than one event with different signatures you'd have to do this:
VB Code:
Private Sub ComboBox1_Leave(ByVal sender As Object, ByVal e As System.EventArgs) Handles ComboBox1.Leave
Me.DoSomething()
End Sub
Private Sub ComboBox1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ComboBox1.SelectedIndexChanged
Me.DoSomething()
End Sub
Private Sub DoSomething()
'Place code here.
End Sub