VIIF calls the write routine to write data records for the CREATE and REPLACE commands when the dialog is handling the processing for these commands. The write routine is called repeatedly to write the data records selected for the CREATE or REPLACE command. Flags are passed to the write routine to indicate the source and change status for each record.
The dialog-supplied write routine is invoked with these parameters:
Source bits:
1 = original record
2 = internal move (Move line command)
3 = internal copy/repeat (Copy/Repeat line commands)
4 = external move (MOVE primary command)
5 = external copy (COPY primary command)
6 = text inserted (TE line command)
7 = typed inserted (Insert line command)
Change bits:
8 = record changed (global bit; set for all changes)
9 = data overtyped
10 = change command (CHANGE primary command)
or overlay change (Overlay line command)
11 = columns shifted ((,((,),)) line commands)
12 = data shifted (<,<<,>,>> line commands)
13 = text change (TE, TF, TS line commands)
14 = record renumbered
15-32 = unused
Multiple bits may be set on, indicating that more than one modification has occurred for the record. For example, a data record that is inserted by using the INSERT line command and is later included in a text flow operation would have bits 7 (typed inserted), 8 (change), 9 (data overtyped) and 13 (text changed) turned on.
Records read in for the initial display are flagged as original records. Whenever there is hidden data, the inaccessible portion of inserted records contains blanks. Records are copied in their entirety; that is, including both the visible and hidden portions of the data. Deleted records are not presented to the write routine.