Navigation: ABC Library Reference > EditFontClass > EditFontClass Methods >====== TakeEvent (process edit-in-place events:EditFontClass) ====== | ![]() ![]() |
TakeEvent( event ), VIRTUAL
| TakeEvent | Processes an event for the EditFontClass object. |
| event | An integer constant, variable, EQUATE, or expression that contains the event number (see EVENT in the Language Reference). |
The TakeEvent method processes an event for the EditFontClass object and returns a value indicating the user requested action. Valid actions are none, complete or OK, cancel, next record, previous record, next field, and previous field.
Implementation:
The BrowseClass.AskRecord method calls the TakeEvent method. The TakeEvent method processes an EVENT:AlertKey for the edit-in-place control. On EVENT:DroppingDown, TakeEvent invokes the Windows font dialog and stores the font specification in the edited field specified by the Init method. Finally, TakeEvent returns a value indicating the user requested action. The BrowseClass.AskRecord method carries out the user requested action.
Corresponding EQUATEs for the possible edit-in-place actions are declared in ABEIP.INC as follows:
EditAction ITEMIZE(0),PRE
None EQUATE ! no action
Forward EQUATE ! next field
Backward EQUATE ! previous field
Complete EQUATE ! OK
Cancel EQUATE ! cancel
Next EQUATE ! next record
Previous EQUATE ! previous record
Ignore EQUATE ! no action
END
Return Data Type: BYTE
Example:
EditClassAction ROUTINE
CASE SELF.EditList.Control.TakeEvent(EVENT())
OF EditAction:Forward !handle tab forward (new field, same record)
OF EditAction:Backward !handle tab backward (new field, same record)
OF EditAction:Next !handle down arrow (new record, offer to save prior record)
OF EditAction:Previous !handle up arrow (new record, offer to save prior record)
OF EditAction:Complete !handle OK or enter key (save record)
OF EditAction:Cancel !handle Cancel or esc key (restore record)
END
See Also: Init, BrowseClass.AskRecord





