Maximum request length exceeded

D

DavidC

I have an aspx web page that has a button using NavigateURL to point to the
startup page. I am getting the following error opening the startup page
(Default.aspx) when I have a very large GridView displayed in the preceding
page. Can anyone help resolve? Thanks.

An unhandled exception occurred:
Message: Maximum request length exceeded.

Stack Trace:
at System.Web.HttpRequest.GetEntireRawContent()
at System.Web.HttpRequest.FillInFormCollection()
at System.Web.HttpRequest.get_Form()
at System.Web.HttpRequest.get_HasForm()
at System.Web.UI.Page.GetCollectionBasedOnMethod(Boolean dontReturnNull)
at System.Web.UI.Page.DeterminePostBackMode()
at System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
 
D

DavidC

The web.config change worked, thanks.
--
David


Brian Cryer said:
<snip>

Have you tried increasing the maxRequestLength in web.config, ie:

<httpRuntime maxRequestLength="8192" />

I know that helps when uploading files - resolves the same (or similar)
error.

As an alternative appraoch, I'm guessing that if your GridView is very large
then that page has an enormous viewstate, and the page is probably quite
slow to load (partly but not just because of the large viewstate). Is it
feasible to turn viewstate off for the gridview?
--
Brian Cryer
http://www.cryer.co.uk/brian

.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,717
Messages
2,569,382
Members
44,704
Latest member
FawnBernay

Latest Threads

Top