将MemoryStream流写入到文件

MemoryStream m = new MemoryStream();

   FileStream fs = new FileStream("C:\\www.xuehi.com.pdf", FileMode.OpenOrCreate);
    BinaryWriter w = new BinaryWriter(fs);
    w.Write(m.ToArray());
    fs.Close();
    m.Close();


类别: c#  查看评论

你可能感兴趣的:(Stream)