System.IO.StreamReader file = new System.IO.StreamReader(textBoxIdModele.Text); string Text = file.ReadToEnd(); file.Close();
List<string> lines = new List<string>(); string line; System.IO.StreamReader file = new System.IO.StreamReader(@"c:\test.txt"); while ((line = file.ReadLine()) != null) { lines.Add(line); }