I의 WriteFile을 사용하여이 파일을 dowloading 서버의 메가 바이트 PDF 나에게 전송 작업이 올바른 메가 바이트 파일 크기를 제공으로 15MB 다운로드, ...Response.TransmitFile 파일 크기 대 C# Response.WriteFile은 문제
인가를 제공해야 이것은 writeFile을위한 서버상의 메모리에 대한 어떤 종류의 압축 해제로 인한 것입니까? 누군가가 일어나고 같은 일을 봤다면 그냥
if (File.Exists(filepath))
{
HttpContext.Current.Response.Clear();
HttpContext.Current.Response.ContentType = "application/octet-stream";
HttpContext.Current.Response.AddHeader("content-disposition","attachment;filename=\""+Path.GetFileName(filepath)+"\"");
HttpContext.Current.Response.AddHeader("content-length", new FileInfo(filepath).Length.ToString());
//HttpContext.Current.Response.WriteFile(filepath);
HttpContext.Current.Response.TransmitFile(filepath);
HttpContext.Current.Response.Flush();
HttpContext.Current.Response.Close();
}
난 그냥 같은 버그를 했어. IIS의 압축 설정은 영향을주지 않습니다. – geofftnz