Solid Edge provides a wide range of COM event sets. Events are used to notify a client that something of interest has occurred in the object. Events are fired by COM objects and no response from the client is expected. In other words, they are simple notifications.
Solid Edge events are available for Mouse, Application, Assembly etc. Some of the events are hit after certain command is invoked and some occur when a command is in progress.
Before implementing any event interface in your code user should first search for the event set in the object browser. Object browser can give you an idea about the member to which this eventset belong to. For example, if you search for AssemblyChangeEvent in object browser you will find that this event set is a member of "SolidEdgeAssembly.AssemblyDocument" whereas if you search for "ApplicationEvents" in object browser you will find that it is a member of "SolidEdgeFramework". While handling any event set you should use appropriate member to avoid exceptions.
Below are two methods available in .NET which can be used to hook-up Solid Edge events.
1. Delegate Event Model
In this approach user has freedom to handle specific event as per requirement. There is a hidden class which is suffixed with _Event. For example, we have ISEApplicationEvent_Event available. Since it is a hidden class, it will not be available through intellisense. You have to add "_Event" manually to resolve this class. Please refer to below sample for more details.
2. Connection Point Model
In this approach after implementing a particular event interface, all the events raised by that interface are handled. While getting a reference to the IConnectionPointContainer make sure that you are using right member for the event set. For example, use application for ApplicationEvents or use AssemblyDocument for AssemblyChangeEvents/AssemblyRecomputeEvents. As shown in below sample code, we will need to leverage the IConnectionPointContainer and IConnectionPoint interfaces from the System.Runtime.InteropServices.ComTypes namespace.
Delegate Event Model
Connection Point Model