블로그 이미지
baragi76

카테고리

분류 전체보기 (115)
생활 (10)
My Story (34)
My Album (1)
HomePage (0)
Hobbies (21)
Develop (42)
Utility (1)
Project (6)
07-27 04:05
Total245,061
Today2
Yesterday7

공지사항

달력

« » 2021.7
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

안정적인 DNS서비스 DNSEver

string destFile = strTempDir + strFileName + ".docx";
FileStream sm1 = File.OpenRead(destFile);

Response.ClearHeaders();
Response.ClearContent();
Response.Clear();

Response.ContentType = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";

Response.AddHeader("Content-disposition", "attachment;filename=" + "OKOK.docx;");
Response.AddHeader("Content-Length", sm1.Length.ToString());

Response.WriteFile(destFile);
Response.Flush();
Response.Close();

sm1.Close();

try
{
 if (File.Exists(destFile))
 {
  File.Delete(destFile);
 }
}
catch (Exception ex)
{
}

Posted by baragi76
TAG ,

댓글을 달아 주세요