大家好, 用C#编程 , 我怎样打开dat 文件
最近要写一个程序, 要求能够打开一个dat文件, 希望C#的高手们能够提示一下, 感 谢了!!!!!!
------解决方案--------------------
FileStream stream = new FileStream(saveFileDialog1.FileName, FileMode.OpenOrCreate, FileAccess.ReadWrite);
BinaryWriter biwrite = new BinaryWriter(stream);
biwrite.Write("");
biwrite.Close();
stream.Close();
FileStream stream = new FileStream(openFileDialog1.FileName, FileMode.Open, FileAccess.Read);
BinaryReader biread = new BinaryReader(stream);
if (biread.PeekChar() != -1)
{
}
biread.Close();
stream.Close();