Several component events going to the same Sub...

  • Thread starter Thread starter nobody
  • Start date Start date
N

nobody

Below I just added the click events after the "Handles"
keyword. Is there a way to do this from the IDE?

****************
Private Sub MenuItem35_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MenuItem35.Click, MenuItem36.Click,
MenuItem37.Click

If sender Is MenuItem35 Then
language = Globals.Keyboard.German
ElseIf sender Is MenuItem36 Then
language = Globals.Keyboard.Italian
ElseIf sender Is MenuItem37 Then
language = Globals.Keyboard.French
End If

End Sub
 
Back
Top