■ Event handlers cannot return values and therefore cannot be defined as a FUNCTION. For example: ┌─Wrong────────────────────────────────────────────────┐ │ FUNCTION Form_Click () │ └──────────────────────────────────────────────────────┘ ┌─Right────────────────────────────────────────────────┐ │ SUB Form_Click () │ └──────────────────────────────────────────────────────┘ ■ Possible solutions: • Use the SUB statement rather than the FUNCTION statement to define event procedures. • Choose Event Procedures from the Edit menu to use the Event Procedures dialog. When you use this dialog, Visual Basic creates the correct event procedure template for you. ■ If you need additional help, move the cursor to a keyword and press F1 to open the Help window.