Was this helpful?
OriginatorField Attribute
Data Type: FieldObject
4GL Access: R
The OriginatorField attribute contains the field defined in the On Event statement that originated the event.
For example, assume that you have a subform called TestSubForm with one field, called TestField. If you define a ChildExit event block whenever you exit TestField, the OriginatorField attribute contains TestSubForm.
This attribute is useful when you have multiple events defining the same event block. For example, if you want to synchronize a radio field and menu list that allow multiple interfaces to the same action, you could use the following code:
on click testradiofield,
on click menu.File.testmenulist =
begin
    if CurFrame.OriginatorField =
        field(testradiofield)then
        testmenulist = testradiofield;
    else
        testradiofield = testmenulist;
    endif;
/* common code goes here */
end
Last modified date: 06/25/2024