When comparing the two signatures:
public delegate void EventHandler<TEventArgs>(Object sender, TEventArgs e);
public delegate void getArterCompletedEventHandler(getArterCompletedEventArgs e);
You can see that the only real difference (with your TEventArgs
) is that one has a sender
, the other does not. Assuming you really want to use these two separate delegate types, you can do this to make it work, by passing in a null
sender
.
EventGetArterCompleted += ea => e(null, ea);
Or if your ServiceAgentArt
instance should be the sender:
EventGetArterCompleted += ea => e(this, ea);
It might make more sense to only use EventHandler<getArterCompletedEventArgs>
, and remove your delegate type.