Overview | Methods | This Package | All Packages
Filters out a message before it is dispatched.
Syntax
public boolean preFilterMessage( Message m )
Parameters
m
The message that is to be dispatched. The message cannot be modified.
Return Value
Returns true to filter the message and prevent it from being dispatched, or returns false to allow the message to continue to the next filter or to be dispatched.
Remarks
Use the preFilterMessage method to filter out a message before it is dispatched to a control or form. For example, to prevent the click event of a Button control from being dispatched to the control, you implement the preFilterMessage method and return a true value when the click message occurs. You can also use this method to perform code work that is needed before the message is dispatched. To work with the message after it has been dispatched, use the postFilterMessage method.