asp.net – 回发时超过最大请求长度异常
发布时间:2020-05-23 09:43:08 所属栏目:asp.Net 来源:互联网
导读:我在点击按钮时遇到以下异常,对于在页面加载时在gridview中绑定超过500条记录的asp页面. 我的页面没有任何上传控件.它包含一个文本框,按钮和gridview. 有谁知道为什么会这样. 例外说明: Maximum request length exceeded.Description: An unhandled exceptio
|
我在点击按钮时遇到以下异常,对于在页面加载时在gridview中绑定超过500条记录的asp页面. 我的页面没有任何上传控件.它包含一个文本框,按钮和gridview. 例外说明: Maximum request length exceeded. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 解决方法回发发送回每个控件的视图状态 – 如果您有一个巨大的数据网格,那么当浏览器将其重新发送到服务器时,这就是您获得异常的原因.你有两个选择: >如果您不需要视图状态,请在GridView上设置EnableViewState =“false”,因此它不是那么臃肿而且回发是合理的大小, <configuration>
<system.web>
<httpRuntime maxRequestLength="32768" />
</system.web>
</configuration>
希望这可以帮助 (编辑:安卓应用网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
推荐文章
站长推荐
- asp.net-mvc – ASP.NET MVC – 主页面和视图页面
- 如何在ASP.NET应用程序中记录错误(异常)?
- asp.net-mvc-3 – 如何在MVC路由中组合CatchAll和
- iis-7 – 在iis7上设置经典的asp站点,站点运行但
- asp.net-web-api – owin cors或web api cors
- 验证 – ASP.Net MVC3电子邮件/电话数据注释不起
- Asp.NET DropDownList在PostBack之后重置Selecte
- asp.net-mvc – 将id类型从string更改为int时,如
- asp.net – 使用jQuery显示ashx图像?
- asp.net-mvc – 禁用某些字段的验证
热点阅读
