Um, if your event declaration is like this:
Code:
Public Event PublicEventUserGram As EventHandler
then you don't raise the event like this:
Code:
RaiseEvent PublicEventUserGram(Me, MyMouseEventArg)
You raise it like this:
Code:
RaiseEvent PublicEventUserGram(Me, EventArgs.Empty)
If you do want to raise it like this:
Code:
RaiseEvent PublicEventUserGram(Me, MyMouseEventArg)
then you declare it like this:
Code:
Public Event PublicEventUserGram As EventHandler(Of MyMouseEventArg)
The event handler should then look like this:
Code:
Private Sub SomeMethod(sender As Object, e As MyMouseEventArg)
You can handle the event with a method like this:
Code:
Private Sub SomeMethod(sender As Object, e As EventArgs)
because MyMouseEventArg inherits EventArgs but, unless MyMouseEventArg inherits MouseEventArgs, you cannot handle it with a method that looks like this:
Code:
Private Sub SomeMethod(sender As Object, e As MouseEventArgs)
By the way, you should follow convention and name your class MyMouseEventArgs.