Difference between revisions of "TStringList.GetText"

From Soldat Community Wiki
Jump to: navigation, search
(new page)
 
(No difference)

Latest revision as of 15:23, 24 August 2013

function GetText(): PChar
 Result: contents of a stringlist as PChar

Description

Function returns the contents as a PChar; series of strings, separated by an end-of-line marker.

Example

var
  s: TStringList;

begin
  s := File.CreateStringList();
  s.Append('a');
  s.Append('b');
  
  WriteLn(s.GetText);
  {
  a
  b
  
  }
  
  s.Free;
end.