Insert a Record

Note: A new record is immediately padded to its minimum length with the character you specify in the Preferences section.
  1. In the Micro Focus Data File Tools window, ensure you have a data file open. If you are in Shared mode, click The Switch to Exclusive Mode icon (Switch to Exclusive Mode).
  2. Right-click the required record, then select Insert Record Before or Insert Record After, as appropriate.
    Note: If the file currently has no records or is an indexed file, select Insert Record.

    If you are inserting a record into a data file that is using a structure file, the Select Structure dialog box appears.

    The Select Structure dialog box

  3. Select the required layout from the structure file in use, then click OK. (An additional layout (Use padding byte) is also available, which is always equal to the minimum record length of the file, and when selected initializes each field to the padding character specified in the Preferences section.)

    The record length is set according to the selected layout; the fields are initialized to default values (according to the field type); however, if you have selected a conditional layout, it is not displayed until the conditions within it are met.

    The green bar indicates where the record will be inserted.

    Data file showing record insertion indicator

    The editor switches to Insert mode, as indicated in the status bar.

    Insert Mode indicator in the status bar

  4. If the data file is unformatted (that is, not using a record layout), type the new record text in the free-text editing field in the bottom pane, then press Enter.

    For files with variable record lengths that are not using a layout, the length of any new record defaults to the file's minimum record length, but you can enter text up to the record's maximum length.

  5. If the data file is formatted, type the new record text in the layout fields, pressing Enter to move to the next field.
  6. Click The Save Record icon (Save Record) to save the record.
  7. If you are not using a temporary file for your edits, you are prompted to save the new record to the file: click Yes to confirm. If you are using a temporary file for your edits (indicated by [TEMP] displayed in the file lock indicator), click Save all changes to file icon (Save all changes to file) after all your edits are made.