TStrings.LoadFromFile procedure
Load the contents of a file as a series of strings.
Declaration
procedure LoadFromFile(const FileName: string); virtual; overload
procedure LoadFromFile(const FileName: string; IgnoreEncoding: Boolean)
procedure LoadFromFile(const FileName: string; AEncoding: TEncoding)
; virtual; overloadDescription
LoadFromFile loads the contents of a file into the stringlist.
Each line in the file (as marked by the end-of-line marker of the
particular OS the application runs on) becomes one string in the stringlist.
This action replaces
the contents of the stringlist, it does not append the strings to the
current content.
LoadFromFile simply creates a
file
stream with the given filename, and then executes
LoadfromStream; after that the file stream object
is destroyed again.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
