Gets the number assigned to a field in the table description.
Number := Record.FIELDNO(Field)
- Type: Record The name of the record that contains the field.
- Type: Field The name of the field in the record.
Property Value/Return Value
The number of the field specified.
This example requires that you create the following variables.
Num := CustomerRec.FIELDNO("No.");
This statement assigns the number of the No. field in the CustomerRec record to the number variable.
In this example, the FIELDNO function is used to determine which field that a variable, which contains a field number, points to in a record. This example requires that you create the following variables.
CASE CurrentFieldNo OF Customer.FIELDNO("No."): ... Customer.FIELDNO(Name): ... Customer.FIELDNO(Address): ... ELSE ... END;
This construct allows you to take actions based on the field number contained in the CurrentFieldNo variable.