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

TStrings.Count

Number of strings in the list.

Declaration

Source position: classesh.inc line 769

public property TStrings.Count : Integer
  read GetCount;

Description

Count is the current number of strings in the list. TStrings does not implement this property; descendant classes should override the property read handler to return the correct value.

Strings in the list are always uniquely identified by their Index; the index of a string is zero-based, i.e. it's supported range is 0 to Count-1. trying to access a string with an index larger than or equal to Count will result in an error. Code that iterates over the list in a stringlist should always take into account the zero-based character of the list index.

See also

TStrings.Strings

  

Indexed access to the strings in the list.

TStrings.Objects

  

Indexed access to the objects associated with the strings in the list.

TStrings.Capacity

  

Capacity of the list, i.e. number of strings that the list can currently hold before it tries to expand.


Documentation generated on: May 14 2021