I know how to (almost) create a plugin
you need to create an interface which a plugin implements.
You also need to create an interface which allows the "host" to be known to the plugin (your application)
thats all cool.
But now, how do I register events from the plugin to the main application (host) so that if I raise an event in the host, the plugins who have these events will also be notified/alerted/executed of the event?
I have a delegate which has a string signature:
public delegate void DoSomething(string text);
event:
public event DoSomething OnEventDoSomething;
the event is in the plugin, and an eventhandler has been created.
but now after loading the assembly/instantiating the plugin from the host, how can I register the event and execute it?
Thanks :)
