IStringList.Remove

Syntax

Remove(Value: String);

Parameters

Value. Value of the element that should be removed.

Description

The Remove method removes the element, which value is passed by the Value parameter.

Example

Sub Main;

Var

StrL: IStringList;

i: Integer;

Begin

StrL:=New StringList.Create;

For i:=0 To Math.RandBetweenI(50,100) Do

StrL.Add("Number "+Math.RandBetweenI(0,100).ToString);

End For;

StrL.Remove("Number 25");

End Sub Main;

After executing the example a dynamic array of strings is generated, and element with the Number 25 value is removed from it, if it exists.

See also:

IStringList