IIS 6 and local(Developer Environment - Win XP + VSS 2010) are working properly.
When we deployed to IIS 7.5, the browser didn't prompt the download window and appear "IE cannot display the webpage" .
Enclosed the source code for your reference.
Download.aspx.vb
Response.ClearHeaders()
Response.Clear()
Response.Expires = 0
Response.Buffer = True
Response.AddHeader("Accept-Language", "zh-tw")
Response.AddHeader("content-disposition", "attachment; filename=" & Chr(34) & Server.UrlEncode(rs("Name")) & Chr(34))
Response.AddHeader("Content-Length", rs("Size") * 1024)
Response.ContentType = "Application/octet-stream"
Response.BinaryWrite(rs("Body"))
Response.Flush()
Response.Close()
Web.Config
<httpRuntime executionTimeout="3600" maxRequestLength="2097151"
requestLengthDiskThreshold="80" useFullyQualifiedRedirectUrl="false"
minFreeThreads="8" minLocalRequestFreeThreads="4" appRequestQueueLimit="5000"
enableKernelOutputCache="true" enableVersionHeader="true" requireRootedSaveAsPath="true"
enable="true" shutdownTimeout="900" delayNotificationTimeout="50"
waitChangeNotification="0" maxWaitChangeNotification="0" enableHeaderChecking="true"
sendCacheControlHeader="true" apartmentThreading="false" />
Please help
Thanks for your kindly attention!