CLEAR field-list

The CLEAR field-list instruction clears specific fields in the current form.

Syntax

CLEAR field-list
where field-list is:
{ field-name
| table-name.*
| table-name.field-name
| screen-array[line].*
| screen-array[line].field-name
| screen-record.*
| screen-record.field-name
}
[,...]
  1. field-name is the identifier of a field of the current form.
  2. table-name is the identifier of a database table of the current form.
  3. screen-record is the identifier of a screen record of the current form.
  4. screen-array is the screen array that will be used in the form.

Usage

The CLEAR field-list instruction can be used to clear the content of the specified form fields

Similarly to CLEAR FORM, the CLEAR field-list is typically used when the program is not inside a dialog block execution controlling the form fields. For example, after a database query with a CONSTRUCT instruction, you might want to clear all search criteria entered by the user with this instruction, to cleanup the form.

The CLEAR field-list instruction is usually not needed if the program is always in the context of a dialog controlling the form fields.

  CONSTRUCT BY NAME sql
     ON s_customer.*
     ...
  END CONSTRUCT
  CLEAR s_customer.*
  ...