Print this Page
1.6 Architect
15. Function Clone
Close this Page

1.6.15. Clone Function:
Any record that is shown on a form may be cloned as a new record with the same data values.   Where a manager can create a new user, the user must be granted right that are identical to or less than those of the manager creating the new user.
The Clone function is almost identical to the Add function except that the initial set of values are copied from a selected record.
The Clone function and the Change function have a very similar behaviour in that a set of field values may be changed.

Clone Action:
When a clone form is shown, the data has already been cloned and a set of complete and correct feild values are stored in the database.   It is not possible for a user to forget to save cloned data - it is already saved and field values can only be changed.   As each field value is changed, it is automatically saved after a backup copy fo the original field value is recorded in the history audit trail - every field value change is also recorded in the "What Did I Do" audit trail to form a pair of interlocking audit trails that reference one another and cannot be changed.

 
4GL Clone Function Architecture:
FORM and INSERT with KEY as the label is the only difference between an add and clone function.

4GL Cancel Menu Option:
MENU and CLICK with CANCEL will physically remove the current record and transfer to the web page identified in the Link.   The Link field value is typically the associated List function passing any applicable keys.