473,386 Members | 1,706 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

ASPX error using response.writefile -"the server reset the connect

We are streaming a PDF file out of an ASPX page in IIS 5 using Response.WriteFile so the user does not need permissions to the directory where the files are stored. This works great when the user is on a fairly fast network connection or when the PDF is not too large. However, for users on slow connections that try to download a large PDF (+30meg), they receive a "the server reset the connection" error message after about 15 minutes of downloading. We tried increasing the Server.ScriptTimeout of the ASPX but without success probably because the ASPX itself executes fairly quickly, it's just the data stream download to the client that is taking so long. What is causing the timeout and can we increase it?
--
Thanks,
Chris.
Nov 18 '05 #1
4 5409
I think you can set timeout to be longer in the web.config. Do a google search and you should come up with something. I can't remember off the top of my head

"whoopdaddy" wrote:
We are streaming a PDF file out of an ASPX page in IIS 5 using Response.WriteFile so the user does not need permissions to the directory where the files are stored. This works great when the user is on a fairly fast network connection or when the PDF is not too large. However, for users on slow connections that try to download a large PDF (+30meg), they receive a "the server reset the connection" error message after about 15 minutes of downloading. We tried increasing the Server.ScriptTimeout of the ASPX but without success probably because the ASPX itself executes fairly quickly, it's just the data stream download to the client that is taking so long. What is causing the timeout and can we increase it?
--
Thanks,
Chris.

Nov 18 '05 #2
Hi Chris,

From your description, you encoutnered the "Connection reset" error
sometimes when the user is downloading a file (with large size and not very
fast newwork bandwidth), yes?

Generally, such issues is likely due to the timeout setting for the IIS or
ASP.NET, as you mentioned that you've tried the Server.ScriptTimeout and
with no success, I think you can also have a look at the "executionTimeout"
attribute in the <httpRuntime> configuration element for asp.net, here is
the reference in MSDN:

#<httpRuntime> Element
http://msdn.microsoft.com/library/en...pruntimesectio
n.asp?frame=true

Also, I think it's better to write the file via a buffer field rather than
directly write into the response stream by response.write file, you may
have a look at the following kb article for some reference.

#PRB: Response.WriteFile Cannot Download a Large File
http://support.microsoft.com/?id=812406

In addition, if you still have no success on this problem. I suggest that
You have a look at the IIS log or feel free to post here so that we can
also have a look to see whether it provides any clues. Thanks.
Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

Nov 18 '05 #3
Hi Chris,

Thanks for your followup. AS you mentioned that the timeout problem still
occurs, I think you can have a try using the buffering output means
mentioned in the following kb article:

#PRB: Response.WriteFile Cannot Download a Large File
http://support.microsoft.com/?id=812406

Using a buffer to output the stream content may be more efficient when the
file size if large. Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

Nov 18 '05 #4
Hi Chris,

Have you got any further progress on this issue? If there're anything else
we can help, please feel free to post here.

Thanks.

Regards,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Get Preview at ASP.NET whidbey
http://msdn.microsoft.com/asp.net/whidbey/default.aspx

Nov 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Jim | last post by:
Any idea what is causing this error? 006~ASP 0230~Server.Transfer Error~The call to Server.Transfer failed while loading the page. Just read about benefits of Server.Transfer over...
4
by: David Moore | last post by:
Hello I am using the System.DirectoryServices namespace classes to access Active Directory. We connect using the LDAP://DOMAIN method. The code works on local dev boxes, and in staging, but...
0
by: s_erez | last post by:
Hi, This is a realy tricky one. I have an ASP.NET application where some pages are reading data from a DB and presenting reports. In order for the user to wait while the page is reading data from...
12
by: James Lankford | last post by:
Hello group: I have reached the end of my rope with this error. I have pretty much tried every suggestion I've found thus far and I get this error no matter what I do. I did try using the CDOSYS...
1
by: Adrian Turner | last post by:
I am just starting developing with .Net(Have used asp for years). I have created a very simple upload page which once uploaded opens the file(excel) and displays the data. If I Attempt to re-run...
3
by: namewitheldbyrequest | last post by:
"The XML element 'EnableTheming' from namespace 'http://tempuri.org/' is already present in the current scope" I created a Web Service: I imported System.Data.SqlClient so I could access SQL...
1
by: Mad Scientist Jr | last post by:
For some reason I can't get a WebClient to access an outside URL from behind our firewall. The code works when it runs outside the firewall. I turned on windows authentication in the web.config...
5
by: Nathan Sokalski | last post by:
I am attempting to send an email using ASP.NET 1.1's Mail.SmtpMail.Send() method. My code contains all of the following: Dim mailmsg As New Mail.MailMessage Mail.SmtpMail.SmtpServer =...
14
by: Warren Tang | last post by:
Hi I am using the mail function to send a mail like this: $b = mail("my_real_email_address@gmail.com", "Hello from PHP", "Hi, finally sent an email successfully"); But it failed. Could you...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.