So far I have created a display manager class, that internally creates a thread listening on a socket for commands. That all works fine, the main thread generates numbers on a display and sending a message from a client on my pc will display that message on the display.
Now when my displaymanager recieves a command code on the socket I want to pass that command back to the main program. On the pc I would usually use an event. When I looked for EventHandler<> I could only find something called NativeEventHandler. Is that the N+ equivalent of EventHandler?
What is the equivalent of my pc code
public event EventHandler<StringEventArgs> ReceivedCommand; ... In Some function if (ReceivedCommand != null) ReceivedCommand(this, new StringEventArgs(command));
Or, as is highly probable, am I going about this in the wrong way.
By the way, a lot of this code is by others from the forum so if you recognise your own code, profound thanks. I will reference everyone in the finished article.
Alan