Public Class Main
    Private Sub ClickHandler(ByVal sender As System.Object, _
     ByVal e As System.EventArgs) Handles cmdA.Click, cmdB.Click, cmdC.Click

        Dim ctrl As Control

        ' Convert the unidentified sender object to a more useful form.
        ctrl = CType(sender, Control)

        MessageBox.Show("You clicked the button called " & ctrl.Name, "Event Tracker")

    End Sub
End Class