title: How to read a text file into string in minimum lines of code?
body: <p>What is the shortest code solution in Delphi to read the content of a file and return the content as a string?</p>
  <p>My poor solution:</p>
  <pre><code>var 
    MyFile: TStringList;
    Content: String;
  
  .....
  Myfile := TStringList.Create;
  try
    MyFile.Loadfromfile(InFilename);
    Content := MyFile.Text;
  finally
    MyFile.free
  end;
  </code></pre>