解决方案 »
- HttpModule一个很奇怪的问题
- 为什么不能建立ASP.NET文件?
- (菜鸟问题)
- 无法创建ASP文件,怎么办呀???大家帮帮忙!!!急!!!
- web部署问题,请前辈多多指教
- 求一自定义分页方法。要求多表连接,用数据集(.xsd)实现。
- 请问对两个分别用ASP.NET和JSP实现的WEB应用,能够实现single sign on吗?
- 使用vb做编写的时候,如何使用xmlhttp来post一个xml文档?
- Url中有http://www.xxx.com/xxx.do,do是什么语言来写的???
- 怎样做这样的一个表?
- RegisteredUser usr = db.RegisteredUsers.FirstOrDefault(a => a.LoginName == login
- C#中,如何获取带有kindeditor的textare中的值
<%= Request.Form["a2"].ToString().Length >=10 ?Request.Form["a2"].Substring(0,10):
Request.Form["a2"].Substring(0,Request.Form["a2"].ToString().Length)
%>不知道这个地方可不可以嵌入三元表达式,自己尝试下吧!
后台cs中: public String GetA2Value()
{ string v2 = Request.Form["a2"]; if (v2.Length > 10)
{
return v2.Substring(0, 10);
}
else
{
return v2;
}
}
Parameter name: length
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. Exception Details: System.ArgumentOutOfRangeException: Index and length must refer to a location within the string.
Parameter name: length再测试一下二楼结果……