RDD

FieldName()

Return a field name by position

Syntax

Signature
FieldName( nPosition ) --> cFieldName

Arguments

nPosition

One-based field position.

Return value

Field name, or an empty string for an invalid position.

Description

FieldName() returns the name of a field in the current work area by its position.

Notes

It does not change the current record.

Example

FieldName.prg
PROCEDURE Main()

   DbUseArea( .T., , "people.dbf", "People" )
   QOut( "Field 1: " + FieldName( 1 ) )
   DbCloseArea()

RETURN

Output

See also