This page describes formula events specific to Button, DragDrop and FlexEditor controls. These controls use component-specific execution paths. The declared common variables Argument_EventName, Argument_SenderName and Argument_SenderID are not populated by the paths described below.
Runs when the button is clicked and its default formula is valid. The Result is ignored and is not copied to CurScriptResult.
Platform differences: Desktop permits execution in Edit and Read Only DBForm modes and always recalculates after the formula, including after a calculation error. Web permits execution only in Edit mode and does not perform a server-side recalculation on this path. Normal button availability is also controlled separately by the component's Disabled/Read Only setting.
Example: Record the last button click.
CIP_SetRuntimeVariable("LastButtonClick", Now());The DragDrop control and its formula events are available only on desktop. All three events declare Argument_MouseX, Argument_MouseY, Argument_Color, Argument_ColorName and Argument_ArgCompName. The first four are populated. Due to an implementation mismatch, Argument_ArgCompName is not populated; the executor writes the target control's own name to an undeclared variable named Argument_CompName.
Runs on a mouse-down over the image after the coordinates and mask color have been read. The handler does not restrict execution to the left mouse button. NeedResult=True; only a Boolean True Result calls BeginDrag.
Example: Start dragging only from the mask area named Movable.
Result := Argument_ColorName = "Movable";Runs while an item is dragged over the target image. The coordinates, color and color name describe the target position; the VCL Source object is not passed to the formula. NeedResult=True; only a Boolean True Result accepts the drop.
Example: Accept a drop only over the DropZone mask area.
Result := Argument_ColorName = "DropZone";Despite its name, this formula is connected to the target image's successful drop event. It does not run for every drag termination, cancellation or drop on another target. NeedResult=False and the Result is ignored.
Example: Record the mask area that received the drop.
CIP_SetRuntimeVariable("LastDropColorName", Argument_ColorName);The FlexEditor and both of its formulas are available only on desktop.
Runs from the Flex grid DataController AfterPost event. The edited value has already been posted to the grid's internal data source, but FlexRecordDataSource.Save has not yet written it to the database. The Result is ignored: it cannot cancel the grid post or control the later save.
The direct executor passes the TFrameFlexObjectEditor frame as Sender, does not write CurScriptResult, and does not start a recalculation.
Example: Record that the grid's posted data changed.
CIP_SetRuntimeVariable("FlexGridChanged", Now());Runs before the SQL query that fills an ObjectRef cell's drop-down list. A valid formula on the FlexEditor component has priority; if it is absent, an event formula with the same name on the current object is used.
Arguments: Argument_FlexDataID is the current Flex data-row ID, Argument_FlexRecordID is the current Flex record ID, Argument_FlexEntryName is the main entry name of the Flex cell, and Argument_EntryName is the referenced ObjectRef entry name. The last two are declared with numeric zero defaults although they receive text at runtime. If no Flex record item is supplied, none of the four local arguments is reset.
Result: Null means no custom filter. Any other Result must be the exact name of an existing global OEE filter. An unknown name raises a Filter not found by name exception.
Example: Apply a global filter named ActiveObjects.
Result := "ActiveObjects";