Internet Direct (Indy)
Home
PreviousUpNext
TIdIOHandler.ReadStrings Method

Reads one or more lines of text from the IOHandler into a TIdStrings instance.

Pascal
procedure ReadStrings(
    ADest: TIdStrings; 
    AReadLinesCount: Integer = -1
);
Parameters 
Description 
ADest 
Stores lines of text read from the IOHandler.
 
AReadLinesCount 
Number of lines of text expected from the IOHandler. 

ReadStrings is a procedure used to read one or more lines of text from the IOHandler, and stores the values in the AValue argument. 

AReadLinesCount indicates the number of lines of text expected from the IOHandler. When AReadLinesCount contains 0 (zero) or a negative value, the number of lines of text is read from the IOHandler as an Integer value. Otherwise, the value in AReadLinesCount must be a positive Integer value supplied by the calling procedure. 

ReadStrings calls ReadLn for the number of iterations indicated in AReadLinesCount, and adds each line of text to the string list in ADest. 

Use ReadChar, ReadBytes, or ReadString to access data in the IOHandler buffer as the requested data type.

Internet Direct (Indy) version 10.1.5
Copyright © 1993-2006, Chad Z. Hower (aka Kudzu) and the Indy Pit Crew. All rights reserved.
Website http://www.indyproject.org.
Post feedback to the Indy Documentation newsgroup.