[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'db' (#fcl)

TFieldDefs.MakeNameUnique

Create a unique field name starting from a base name

Declaration

Source position: db.pas line 221

public function TFieldDefs.MakeNameUnique(

  const AName: String

):String; virtual;

Arguments

AName

  

Start of fieldname.

Function result

Unique name, based on AName

Description

MakeNameUnique uses AName to construct a name of a field that is not yet in the collection. If AName is not yet in the collection, then AName is returned. if a field definition with field name equal to AName already exists, then a new name is constructed by appending a sequence number to AName till the resulting name does not appear in the list of field definitions.

See also

TFieldDefs.Find

  

Find item by name

TFieldDef.Name

The latest version of this document can be found at lazarus-ccr.sourceforge.net.