Internet Direct (Indy) Version 9.0.2 Beta
TIdTCPConnection.ReadStrings
Reads a variable number of text lines from a connection.

procedure ReadStrings(var AValue: TStrings; AReadLinesCount: Integer);
Parameters
var AValue: TStrings
Container for values read from the connection.

AReadLinesCount: Integer = -1
Number of lines to read from the connection.

Description
ReadStrings is a procedure that allows the TCP connection to read a variable number of text lines, and store the values in the variable parameter AValue.

AReadLinesCount is the number of lines expected from the TCP connection, or -1 when the connection will contain an Integer that indicates the number of lines to be read. ReadStrings calls ReadInteger to get the line count when AReadLinesCount contains -1.

ReadStrings repetitively calls ReadLn until the number of expected lines has been read from the TCP connection.