0

正如标题所说,我想将 .wiq 文件中的所有文本作为 C# 中的字符串读取。有可能吗?因为普通的 StreamReader 只适用于 .txt!

4

1 回答 1

1

这对我有用。

using( System.IO.StreamReader sr = new System.IO.StreamReader(@"C:\temp\queryName.wiq") )
{
    string allLines = sr.ReadToEnd();
}
于 2016-07-22T20:41:14.350 回答