This question is regarding the "Handles" part of a routine, for
example:
Handles Button1.Click
On Form2 (a User Control) I have a button. Here's it's code:
Public Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
'...
End Sub
Ok, now on Form1, I have a Menu. One of the menu items needs to act
like Button1 was clicked.
I would like to add to the Handles section by adding:
Handles Button1.Click, Menuitem1.Click
This would work if the button and menuitem were on the same form. But
they are on different forms. I get an error saying "Handles clause
requires a WithEvents variable". How do I go about this?
Thanks for your help!
John