A script-enabled browser is required for this page to function properly.

Initialization

When a form is initialized, three things happen in the following order:

  1. The Pre-Form trigger is fired
  2. The data block is initialized if the status of the record is NEW.
  3. The Pre-Block trigger is fired. Default values are assigned as part of (2).

Oracle Forms creates a null record in each block of the form. Each item of a null record is also null. Oracle Forms replaces the null record with an initialized record the first time it enters the block. At that time it gives initial values to some items. An item's Initial Value property specifies the item's initial value.

When a form is initialized, each block is set to a "null" block: a block containing a single "null" record. (All the items in the record have a null value). Whenever Forms navigates into a null block (e.g. because of a GO_BLOCK or because of end-user action), it replaces the block's null record by an "initialized" record: each item in the record is set to the value of its "Initial Value" property. Formula items in a block are calculated when an initialized record is created, but not when a null record is created.

Note that if a form programmatically assigns a value an item in a null block, then it is no longer a null block, and its single record never gets initialized, even when Forms navigates to the block. When Forms inserts a new record into a non-null block, the new record is initialized.

The "Single Record" property also has impact on the block property: if it's Yes, then form initialization sets the block to a single initialized record (rather than to a null record).

Note: If a trigger assigns a value to an item in a null record, the record is no longer null. Oracle Forms never assigns an initial value to any item in the record. For example, a PRE-FORM trigger fires while the form contains only null records. If it assigns a value to an item, it must ensure that all other items of the record receive appropriate initial values.

Special considerations apply to certain types of items:

Check boxes

The initial value determines whether the check box is initially checked or unchecked. You must specify a valid initial value unless one of the following is true:

Note: A check box in a null record appears unchecked.

List items

You must specify a valid initial value unless one of the following is true:

Note: A List item in a null record appears blank.

Radio groups

You must specify a valid initial value unless one of the following is true:

Note: A radio group in a null record appears with no radio button selected.

Synchronized items

If items, say B and C, have their Synchronize with Item properties set to the name of another item, say A, then A, B, and C form a set of synchronized items. A is the master item of the set, and B and C are subordinate items. Synchronized items were called mirror items in earlier versions of Oracle Forms.

The items of a synchronized set share a common data value, but can have different item properties. Oracle Forms takes data-specific properties and triggers from the master item and ignores those properties and triggers for the subordinate items.

Oracle Forms initializes synchronized items from the master item's Initial Value property. Oracle Forms also uses the master item's ON-SEQUENCE-NUMBER trigger.

If the designer specifies an Initial Value property or an ON-SEQUENCE-NUMBER trigger for a subordinate item, Oracle Forms ignores them and issues a warning.

Oracle Forms ignores an item's Initial Value property if all of the following are true for the item (or an item synchronized with it):