Platform SDK: Exchange Server |
When a Microsoft Exchange user changes the selection within a window or changes which object’s contents are being displayed in a window, a user event is sent to Microsoft Exchange extensions. Within the main Viewer window, the selection can be a message store, a folder, or a message. Within the Find window or the Remote Mail window, the selection is always a message. Within the Address Book, it is an address entry.
Extensions that should be notified whenever a selection or object changes must implement the IExchExtUserEvents : IUnknown interface. This interface includes two methods: IExchExtUserEvents::OnSelectionChange and IExchExtUserEvents::OnObjectChange. Whenever a selection or object changes, Microsoft Exchange calls these methods on all extensions that were installed for that context.
The two IExchExtUserEvents methods only pass the extension a pointer to the IExchExtCallBack : IUnknown interface, which provides information about the current selection. Using this information, the extension can then act appropriately. For example, it can enable or disable a toolbar button.