Key precedence at runtime

When you create client, display, or object keys in FactoryTalk View SE, you redefine the behavior of a key, or key sequence, to suit your application. This can result in a key having more than one action defined for it, for example, if you assign an object key definition to a reserved key, or to a key that has another definition within an embedded object. To ensure predictable behavior at runtime, FactoryTalk View observes some rules of precedence for configured keys that determine what will happen when a particular key, or key sequence, has more than one action defined for it.
There are three levels of precedence. These are from highest to lowest:
Level 1: Object keys
Object keys always take precedence over display keys or any of the level 3 keys. This means that if a particular key or key sequence has an action assigned to it as an object key, that is the only action that will be performed when the object has focus and the key is pressed. If the key is a reserved key in FactoryTalk View, or has any other actions assigned to it, for example as a client key, those actions will not be performed. This lets you disable reserved keys.
Level 2: Display keys
Display keys take precedence over client keys or any of the other level 3 keys. This means that if a particular key, or key sequence, has an action assigned to it as a display key (and not an object key), that is the only action that will be performed when the display has focus and the key is pressed. If the key has any level 3 actions assigned to it those actions will not be performed. Like object keys, display keys also let you disable reserved keys.
Level 3: Client keys, reserved keys, and keys in an ActiveX or FactoryTalk View object
The actions assigned to client keys, reserved keys, and keys that are in embedded objects, will only be performed if there are no higher level actions defined for the same key. Client keys are available at runtime on the FactoryTalk View SE Client regardless of which display or graphic object has focus.
If a reserved key, or reserved key sequence, also has a client action defined for it, both actions will be performed when the key is pressed, providing that there is not a higher level action also assigned. Because the behavior is unpredictable, this practice is not recommended.
If a key embedded in an OLE object or ActiveX control, also has a client key definition, when the object or control has focus and the key is pressed, the client key action is carried out as well as the action within the control or object. For this reason, it is important to be aware of the significant keys in any embedded objects or controls you use, so that you do not inadvertently create unpredictable behavior in your application.
Remarks
When a non-FactoryTalk View embedded OLE object, such as a Microsoft Excel worksheet, has focus, its keys always take precedence over all three levels of keys defined above. This means that if, for example, a key has both a display action assigned to it and an action assigned to it within the Excel worksheet, when the Excel worksheet has focus, its key action will be carried out and the display key action will not be.
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal