asp.net 错误解决方案--对象的当前状态使该操作无效的解决办法(peration is not valid due to the current state of the object)

错误提示:

异常详细信息: System.InvalidOperationException: 对象的当前状态使该操作无效(Operation is not valid due to the current state of the object)

原因:
出现这个异常的原因正是因为2012年12月29号那次微软发布的最后一次非正常更新程序引起的.在这次安全更新中对于asp.net单次的提交量做了一个最大量限制1000,如果页面提交数据大小超过了1000这个限制就会报这个错误。

解决办法:

计事本打开web.config文件,在这行前面添加下面红色的内容,如下。

....

你可能感兴趣的:(ASP.net网站知识)