title: C# How to read embedded resource text file with File.ReadLines?
body: <p>How can I do that?
  My string for hello.txt is:</p>
  
  <pre><code>string hello = Properties.Resources.hello;
  </code></pre>
  
  <p>and I want it so:</p>
  
  <pre><code>Random rand = new Random();
  IEnumerable&lt;string&gt; lines = File.ReadLines(hello);
  var lineToRead = rand.Next(1, lines.Count());
  var line = lines.Skip(lineToRead - 1).First();
  txtbx_output.Text = line.ToString();
  </code></pre>
  
  <p>This here works for me with no problems:</p>
  
  <pre><code>IEnumerable&lt;string&gt; lines = File.ReadAllLines(@"my pathblabla\Text\hello.txt");
  </code></pre>
  
  <p>but not as a resource !</p>
  
  <p>This makes me very angry </p>