28,390
社区成员
发帖
与我相关
我的任务
分享
Response.Clear
Response.AddHeader "Content-Disposition", "attachment; filename=" & FileNames
Response.AddHeader "Content-Length", FileSize
'Response.Charset = "UTF-8"
Response.ContentType = getFileContentType(FileExt)
Set Stream = server.CreateObject("ADODB.Stream")
Stream.Type = adTypeBinary
Stream.Open
Stream.LoadFromFile FilePath
While Not Stream.EOS
Response.BinaryWrite Stream.Read(BinaryData)
Wend
Stream.Close
Set Stream = Nothing
'Response.Flush
'Response.End