关于 error: Operation is not valid due to the current state of the object。
今天碰到一个特别的异常。
Operation is not valid due to the current state of the object.
at System.Web.HttpValueCollection.ThrowIfMaxHttpCollectionKeysExceeded()
at System.Web.HttpValueCollection.FillFromEncodedBytes(Byte[] bytes, Encoding encoding)
at System.Web.HttpRequest.FillInFormCollection()
后来发现,客服端post过来的参数,传过来一大堆不用的,但感觉也不应该会抛异常啊。
后来把参数纠正后(减少了很多post过来的参数),就正确了。
但不甘心,又网上搜索了下,查到如下解决方法:
<configuration>
<appSettings>
<add key="aspnet:MaxHttpCollectionKeys" value="5000" />
</appSettings>
</configuration>
开来FillInFormCollection,是有个数限制的。以后得多多注意。
关于 error: Operation is not valid due to the current state of the object。的更多相关文章
- Error occurred in deployment step 'Add Solution': Operation is not valid due to the current state of the object.
Sharepoint 部署的时候出现一个错误 Error occurred in deployment step 'Add Solution': Operation is not valid due ...
- “Operation is not valid due to the current state of the object.”
将Repeater单页显示的2000条数据一次性提交的时候出现这个错误: Operation is not valid due to the current state of the object. ...
- Operation is not valid due to the current state of the object.
今天遇到一个asp.net的草郁闷的问题,看下截图 狂晕啊,在google上狂搜了一下,好在已经有大侠也遇到过这个问题了,先看下别人的解决办法吧 Operation is not valid due ...
- GridView Postback后出错Operation is not valid due to the current state of the object.
一.问题起因 最近项目中有一页面第一次search后正常,但是再次点击其它任何按钮都会报错,亦即postback后页面有问题,经检查是由于页面有一GridView且数据量极大,记录大概有上千条,这儿解 ...
- Failed to decrypt protected XML node "DTS:Password" with error 0x8009000B "Key not valid for use in specified state.". You may not be authorized to access this information. This error occurs when t
Question SSIS包从A服务器搬迁到B服务器,运行报错 Description: Failed to decrypt protected XML node "DTS:Password ...
- kali kvm Requested operation is not valid: network 'default' is not active
安装时候参考的:http://www.ilanni.com/?p=6101 今天安装完kvm,满是幸福的装了个xp,重启后出现了一个错误 Requested operation is not vali ...
- Error: cannot find a valid baseurl for repo: rpmfusion-free 解决办法
今天在玩CentOS的时候出现了: Error: cannot find a valid baseurl for repo: rpmfusion-free 这个问题真到好恶心啊,以前一直使用到是ubu ...
- centos安装软件Error: Cannot find a valid baseurl for repo: base
今天使用yum安装软件,出现下面的提示: Loaded plugins: fastestmirror, refresh-packagekit, securityLoading mirror speed ...
- Yum出错Error: Cannot find a valid baseurl for repo: base(转)
centos yum 错误 Error: Cannot find a valid baseurl for repo: base 装了个CentOS 6.x,使用yum时出现了下面的错误提示.Loade ...
随机推荐
- Apple Watch版微信来了 收发微信刷朋友圈不在话下
昨晚果粉守了一夜的Apple Watch发布会,意料中的惊喜不少,最让人兴奋的是微信成为首批支持的应用.是的,在全球拥有4.68亿月活跃用户的微信怎么可能不第一时间入驻呢?之前我们就有聊过Apple ...
- PHP变量作用域(花括号、global、闭包)
花括号 很多语言都以花括号作为作用域界限,PHP中只有函数的花括号才构成新的作用域. <?php if (True) { $a = 'var a'; } var_dump($a); for ($ ...
- 【Alpha版本】 第一天 11.7
一.站立式会议照片: 二.项目燃尽图: 三.项目进展: 成 员 前段时间完成任务 今天完成任务 明天要做任务 问题困难 心得体会 胡泽善 部分APP功能 我要招聘详情的展示 注册界面的实现 一些特殊效 ...
- CSS实现多个Div等高,类似表格布局
<%@ taglib prefix="tiles" uri="http://tiles.apache.org/tags-tiles"%> <% ...
- Linux串口中的超时设置
在Linux下使用串口通信时,默认的阻塞模式是不实用的.而采用select或epoll机制的非阻塞模式,写代码有比较麻烦.幸好Linux的串口自己就带有超时机制. Linux下使用termios.h中 ...
- DAY6 使用ping钥匙临时开启SSH:22端口,实现远程安全SSH登录管理就这么简单
设置防火墙策略时,关于SSH:22访问权限,我们常常会设置服务器只接受某个固定IP(如公司IP)访问,但是当我们出差或在家情况需要登录服务器怎么办呢? 常用两种解决方案:1.通过VPN操作登录主机: ...
- Cordova phonegap开发环境搭建
1.下载并安装Android Studio, 2.下载并安装nodejs 3.通过nodejs来安装cordova(npm install -g cordova ) 4.使用cordova来创建pho ...
- SQL,Linq,Lambda之间的转换练习
1.查询Student表中的所有记录的Sname.Ssex和Class列. SQL:select sname,ssex,class from Students linq:from s in Stude ...
- poj 3468(线段树)
http://poj.org/problem?id=3468 题意:给n个数字,从A1 …………An m次命令,Q是查询,查询a到b的区间和,c是更新,从a到b每个值都增加x.思路:这是一个很明显的线 ...
- md5 (c语言)
/** * \file md5.h * * \brief MD5 message digest algorithm (hash function) * * Copyright (C) 2006-201 ...