Application_Error and Maximum request length exceeded

  • Thread starter Thread starter Jacky Kwok
  • Start date Start date
J

Jacky Kwok

Dear all:

I know how to use the "Application_Error" in "Global.asax" to catch the
exception and display my own error message page.

However, I found "Application_Error" cannot handle the error of "Maximum
request length exceeded" (in my case, actually too large upload file
size, I know how to modify the "maxRequestLength" to change the upload
size but I need a formal error message in this case).

In VS.NET debugger, program could run into the "Application_Error".
However, no matter I used the

<customErrors defaultRedirect="errorStatus.htm" mode="On"> </customErrors>

or

handling redirect in program code.

The error page of

================
The page cannot be displayed
The page you are looking for is currently unavailable. The Web site
might be experiencing technical difficulties, or you may need to adjust
your browser settings.
.......
Cannot find server or DNS Error
Internet Explorer
===================

displayed.



Anyone know how to handle this problem?


Thank you very much.
 
I've run into this, I couldn't find a way to handle the error either. I'll
do some research on it and let you know what I find out. I didn't find
anything on it before but it's worth another shot.
 
Back
Top