Uniface Learnings
Uniface Learnings
e component. With /e switch It activates the Read trigger of the current entity ($entname) or of Entity. E.g. Retrieve EMP ( EMP is an entity) Error : field EMP not available, it goes into read trigger of outermost entity on the component.
Using new_instance allows you to start several instances of the same component, each known by its own instance name. If the component is a service or report, assignments in the [SERVICES_EXEC] or [REPORTS_EXEC] section of the assignment file determine if the instance is created on the client or server machine. (Instances of form components are always created on the client machine.)
Locating the called module When resolving a call statement, the called module is searched for in this order: 1. 2. 3. 4. In In In In the the the the triggers of the component (for a local Proc module). library specified in the component properties (for a global Proc). library specified in the start-up shell properties (for a global Proc). library SYSTEM_LIBRARY (for a global Proc).
Further information about call resolution and binding can be found in The compilation process. Never use the clear/e statement in the Occurrence Gets Focus or Start Modification triggers. This can cause UNIFACE to enter an infinite loop. The process flow for the <Erase> trigger is as follows: 1. The ^ERASE structure editor function activates the <Erase> trigger. 2. If <Erase> trigger contains the erase statement, the Lock trigger is activated for each occurrence retrieved from a database. 3. If the Lock trigger contains the lock statement, all occurrences are locked in the database. 4. UNIFACE activates the Delete trigger for each occurrence retrieved from the database.
5. Per occurrence, the delete statement in the Delete trigger deletes the occurrence from the database. Most developers disable the <Erase> trigger. Compare the functionality of ^ERASE with the ^CLEAR function which is used to clear the form of data, but does not delete data stored in the database. Next field: This trigger is not activated when the cursor is moved with arrow keys or mouse clicks or by setting $prompt.
Leave Object group of triggers (Leave Field, Leave Modified Key, and Leave Modified Occurrence) Validate -> leave -> next