Action options
When declaring an action in the ACTION statement a certain set of action options may be specified at the end of the declaration.
Syntax
Options are listed one after another in arbitrary order, separated by spaces or line feeds:
propertyOption1 ... propertyOptionN
The following set of options is supported (the syntax of each option is indicated on a separate line):
IN groupName
viewType
ON eventType { actionOperator }
CHANGEKEY key [SHOW | HIDE]
CHANGEMOUSE key [SHOW | HIDE]
STICKY | NOSTICKY
syncType
ASON eventType [ACTION] propertyId
imageSetting
annotationSetting
CONFIRM
EXTID extID
Description and parameters
-
IN groupNameSpecifying the group of properties and actions to which the action belongs. If the option is not specified, then the action will belong by default to the
System.privategroup.-
groupNameA group name. Composite ID.
-
Interactive view block
-
viewTypeSpecifying the type of the action view when added to the form.
GRID- table columnTOOLBAR- toolbarPANEL- panel
It is similar to specifying the viewType option in the property block of the
FORMstatement. Thus, if this option is not specified either in the action options or in the property block directly on the form, the default view of the action display group on the form is used. -
ON eventType { actionOperator }Specifying an action that will be the default handler of a certain event for all the interactive views of this action. Can be overridden in the property block of the
FORMstatement.-
eventTypeA form event type. It is specified by one of the keywords:
CHANGE- occurs when the user tries to change the value of the specified propertyCHANGEWYS- occurs when the user tries to change the value of the specified property using a special input mechanism. You can read more in the description of the form eventsGROUPCHANGE- occurs when the user tries to change the property value for all objects in the table (group editing)EDIT- occurs when the user tries to edit the object that is the value of the specified propertyCONTEXTMENU [caption]- the user has selected the specified item in the property context menu on the form. If necessary, you can also define the caption of this menu item (string literal). If it is not specified, then, by default, it will be the same as the action caption.
-
actionOperatorA context-dependent action operator. An operator that defines the action executed on an event. You can use the parameters of the property itself as operator parameters.
-
-
ASON eventType [ACTION] propertyIdSpecifies that this action will be the default handler of a certain event for all the interactive views of the specified property or action. Can be overridden in the property and action block of the
FORMstatement.-
eventTypeSimilar to the
ONblock. -
propertyIdAn ID of the property or action for which the created action will be executed when the specified form event occurs.
-
ACTIONKeyword. If specified, it is considered that the action is set in
propertyId. If not specified, it is initially considered that a property is defined inpropertyId; otherwise, if no property is found, it is considered that an action is specified inpropertyId.
-
-
imageSettingIcon settings for the action. This option allows you to configure the icon manually. It can have one of the following forms:
-
IMAGE [imageLiteral]Manual icon specification for the action. If
imageLiteralis not provided, the automatic assignment mode is enabled.-
imageLiteralString literal whose value defines the icon.
-
-
NOIMAGEKeyword indicating that the action should have no icon.
-
-
annotationSetting
Action annotation. Begins with @@. The following annotations are supported:
-
@@noauthDisables authorization check for external requests for this action.
-
@@apiWhen the API is disabled, allows external requests for this action.
-
@@deprecated -
@@deprecated(since) -
@@deprecated(since, message)Marks the action as deprecated and not recommended for use. The plugin displays such properties as strikethrough.
-
sinceString literal indicating the platform version since which the action is considered deprecated. -
messageString literal providing an explanation of why the action is marked as deprecated.
-
-
EXTID extIDSpecifying the name to be used for access from an external system.
DESIGN statement default values block
-
CHANGEKEY key [SHOW | HIDE]Specifies a keyboard shortcut which triggers this action. Sets the value for the default design and can be overridden in the
DESIGNstatement.key
String literal, that defines a keyboard shortcut. Syntax:
keyStroke [;(modeKey=modeValue;)*]-
keyStrokeString representation of a key combination. The definition principle is similar to the way the parameter is specified in the Java class method KeyStroke.getKeyStroke(String). (http://docs.oracle.com/javase/7/docs/api/javax/swing/KeyStroke.html#getKeyStroke(java.lang.String)). -
(modeKey=modeValue;)*Options specifying the execution conditions for keyStroke. The following options are supported:-
priority = priorityValuePriority, an integer value. If multiple actions meet the CHANGEKEY conditions, the one with the higher priority will be executed. If the priority is not set, it is equal to the sequential number of the property in the form. Additionally, in any case, 1000 is added to the priority value if the object group matches. -
preview = previewValueAll events are checked for execution twice: first with isPreview = true, then with isPreview = false. SupportedpreviewValuevalues:AUTO,ONLY-> isPreviewNO-> !isPreviewALL-> true
-
dialog = dialogValueChecks whether CHANGEKEY should be executed in a dialog window. SupporteddialogValuevalues:AUTO,ALL-> trueONLY-> isDialogNO-> !isDialog
-
window = windowValueChecks whether CHANGEKEY should be executed in a modal window. SupportedwindowValuevalues:AUTO,ALL-> trueONLY-> isWindowNO-> !isWindow
-
group = groupValueChecks whether the object group matches. SupportedgroupValuevalues:AUTO,ALL-> trueONLY-> equalGroupNO-> !equalGroup
-
editing = editingValueChecks whether CHANGEKEY should be executed in property editing mode. SupportededitingValuevalues:AUTO-> !(isEditing() && getEditElement().isOrHasChild(Element.as(event.getEventTarget())))ALL-> trueONLY-> isEditingNO-> !isEditing
-
showing = showingValueChecks whether the action is currently visible on the form. SupportedshowingValuevalues:AUTO,ONLY-> isShowingALL-> trueNO-> !isShowing
-
panel = panelValueChecks whether the action is located in a panel. SupportedpanelValuevalues:AUTO-> !isMouse || !isPanelALL-> trueONLY-> isPanelNO-> !isPanel
-
cell = cellValueChecks whether the action is located in a table cell. SupportedcellValuevalues:AUTO-> !isMouse || isCellALL-> trueONLY-> isCellNO-> !isCell
For all options except
priority, the default value isAUTO. -
-
SHOWKeyword. When specified, the key combination will be displayed in the action caption. Used by default.
-
HIDEKeyword. When specified, the key combination will not be displayed in the action caption.
-
CHANGEMOUSE key [SHOW | HIDE]Specifies the mouse key combination that triggers this action. Sets the default value for the design, which can be overridden in the
DESIGNinstruction.key
String literaldescribing a mouse key combination. Syntax:
keyStroke [;(modeKey=modeValue;)*]-
keyStrokeString representation of a mouse key combination. Currently, the only supported value isDBLCLK— double click. -
(modeKey=modeValue;)*The syntax is identical to that ofCHANGEKEY. -
SHOWKeyword indicating that the mouse key combination should be displayed in the action header. This is the default behavior.
-
HIDEKeyword indicating that the mouse key combination should not be displayed in the action header.
-
STICKY|NOSTICKYKeywords.
STICKYindicates that the action in the table will be pinned to the left and remain visible when scrolling to the right.NOSTICKYremoves this pinning. By default,STICKYorNOSTICKYis determined heuristically. -
syncTypeDefines whether the action is executed synchronously or asynchronously:
-
WAIT— synchronously. -
NOWAIT— asynchronously. This is the default behaviour.
-
-
CONFIRMKeyword. If specified, the user will be asked to confirm the action when it is executed. Sets the value for the default design and can be overridden in the
DESIGNstatement.