读取text文档 StreamReader 新建-项目-c#控制台应用程序 using System.IO; using System.Windows.Forms; using (StreamReader sr = new StreamReader(@"C:\Users\mj\Desktop\1.txt", Encoding.Default)) { string str = null;