Unit 'Classes' Package
[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] [#rtl]

TStrings.AddPair

Add a name-value pair.

Declaration

Source position: classesh.inc line 992

public function TStrings.AddPair(

  const AName: string;

  const AValue: string

):TStrings; overload;

function TStrings.AddPair(

  const AName: string;

  const AValue: string;

  AObject: TObject

):TStrings; overload;

Description

AddPair adds a Name=Value pair with the AName and AValue parameters, optionally with object AObject. It uses the correct NameValueSeparator character to do so.

AddPair does not test whether aName already exists, so it is possible to add duplicate names.

Errors

None.

See also

TStrings.GetNameValue

  

Return both name and value of a name,value pair based on it's index.

TStrings.NameValueSeparator

  

Value of the character used to separate name,value pairs.

TStrings.Add

  

Add a string to the list.

TStrings.AddObject

  

Add a string and associated object to the list.


Documentation generated on: Dec 22 2024