FileStream fileStream=new FileStream(pFileName,FileMode.Open)
long fileSize = fileStream.Length;
Context.Response.ContentType="application/msword";
Context.Response.AddHeader("Content-Length",fileSize.ToString());
byte[] fileBuffer=new byte[fileSize];
fileStream.Read(fileBuffer, 0, (int)fileSize);
Context.Response.BinaryWrite(fileBuffer);
Context.Response.End();

相关文章:

  • 2022-12-23
  • 2022-02-11
  • 2022-01-08
  • 2021-06-05
  • 2022-12-23
  • 2021-05-29
  • 2022-12-23
  • 2021-11-20
猜你喜欢
  • 2022-02-09
  • 2022-12-23
  • 2021-12-19
  • 2022-03-08
  • 2022-03-03
  • 2021-11-03
  • 2022-01-09
相关资源
相似解决方案