RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TSession.GetFieldNames Method

Populates a string list with the names of all fields in a specified table.

Pascal
procedure GetFieldNames(const DatabaseName: string; const TableName: string; List: TStrings);
C++
__fastcall GetFieldNames(const AnsiString DatabaseName, const AnsiString TableName, TStrings List);

Call GetFieldNames to retrieve a list of all the columns (fields) in a specified table.  

DatabaseName is the name of the database that contains the table. It can be the name of an existing Borland Database Engine (BDE) alias, the name of a TDatabase component's DatabaseName property, or a fully qualified path name for the location of a Paradox or dBASE table. 

TableName is the name of the table for which you want to list the fields. 

List is a string list object, created and maintained by the application, into which GetFieldNames adds the names of all fields in the table specified by TableName. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!