|  | ||
| 
 | The MessageAreaWrite Event | 
 | ||||||
| Synopsis | The MessageAreaWrite event is raised whenever SilverSharp wishes to write text to a message area. Text is written in a message area in response to the SilverScreen API routine message_area_write. 
 | 
 | ||||||
| Delegate | The MessageAreaWrite delegate is declared as follows: 
 
 
 A delegate is similar to a C/C++ function pointer, but delegates are type-safe and can only refer to a method that matches the signature of the delegate. The MessageAreaWrite delegate declares a function signature that must be used when installing an event handler for the MessageAreaWrite event. 
 | 
 | ||||||
| Event | The MessageAreaWrite event is declared within Events as follows: 
 
 
 MessageAreaWrite allows your application to subscribe to or unsubscribe from the MessageAreaWrite event. 
 | 
 | ||||||
| Raise method | The method to raise the MessageAreaWrite event is declared within Events as follows: 
 
 
 The SilverSharp assembly will automatically raise the MessageAreaWrite event when a message is to be written into the message area. It would not be typical for a SilverSharp application to raise the event itself. 
 | 
 | ||||||
| Remarks | It is not necessary for a SilverSharp application to establish a handler for the MessageAreaWrite event, but you must do so if you wish to call SilverScreen API routines that write into the message area. 
 | 
 | ||||||
| See Also | 
 | |||||||
| Example | The following code shows a sample MessageAreaWrite event handler. The implementation of WriteToMessageArea is not shown. Note that the method declaration must match the delegate for this event in parameters and return type: 
 
 
 The following example shows how to subscribe to the MessageAreaWrite event, assigning the above handler: 
 
 
 The following example shows how to unsubscribe from the MessageAreaWrite event, removing the above handler: 
 
 
 
 | 
 |