奔腾年代

但行好事,莫问前程。

导航

2011年3月16日

取得前九条之后的数据

摘要: select Page,Resultfrom ( SELECT *,row_number() over(order by result desc) as rownum FROM B_Record_DomainNamePage WHERE DomainName=@domainname and Type=@type and RecordDate=@estr) as awhere rownum>9 阅读全文

posted @ 2011-03-16 11:12 奔腾年代 阅读(102) 评论(0) 推荐(0) 编辑

List 和 IList的区别

摘要: 使用IList <Class1> IList11 =new List <Class1>(); 方便后期的修改,当你不在使用List 要使用其他类型的时候 只需要修改这一处地方就可以了 不用修改过多的 地方IList <>是个接口,定义了一些操作方法 这些方法要你自己去实现 List <>是个类型 已经实现了IList <>定义的那些方法List <Class1> List11 =new List <Class1>(); 是想创建一个List <Class1>,而且需要使用到List <T> 阅读全文

posted @ 2011-03-16 10:59 奔腾年代 阅读(230) 评论(0) 推荐(0) 编辑

对List(IList)集合作求和,最大(小)值操作

摘要: var sumResult = listIp.Sum(p => p.Result);var maxResult = listIp.Max(p => p.Result);var minResult = listIp.Min(p => p.Result); 阅读全文

posted @ 2011-03-16 10:32 奔腾年代 阅读(517) 评论(0) 推荐(0) 编辑

2011年3月11日

密码请设为6-16位字母或数字的检查

摘要: function Check( ) { if (document.getElementById("txtRePwd").value.length < 6 || document.getElementById("txtRePwd").value.length > 16) { alert("密码长度不符!"); return false; } var parameter = /[a-zA-Z0-9]$/; if (!parameter.test(document.getElementById("txtRePwd&qu 阅读全文

posted @ 2011-03-11 16:42 奔腾年代 阅读(848) 评论(0) 推荐(0) 编辑

2011年3月10日

验证码验证

摘要: using System;using System.Drawing;using System.Web;using System.Web.Services;using System.Web.SessionState;namespace WEB{ /// <summary> /// $codebehindclassname$ 的摘要说明 /// </summary> [WebService(Namespace = "http://tempuri.org/")] [WebServiceBinding(ConformsTo = WsiProfiles.Bas 阅读全文

posted @ 2011-03-10 17:52 奔腾年代 阅读(215) 评论(0) 推荐(0) 编辑

2011年3月8日

必须先判断对象不为空,否则会报空指针错误。

摘要: Request.QueryString["name"] != null && Request.QueryString["name"] != ""fupPicture.PostedFile != null && fupPicture.PostedFile.ContentLength > 0 阅读全文

posted @ 2011-03-08 09:39 奔腾年代 阅读(494) 评论(0) 推荐(0) 编辑

2011年3月3日

asp:TextBox加日历控件

摘要: <link href="http://www.cnblogs.com/JS/jquery-ui-1.8.5.SouthStreet/css/south-street/jquery-ui-1.8.5.custom.css" rel="stylesheet" type="text/css" /> <script src="http://www.cnblogs.com/JS/jquery-ui-1.8.5.SouthStreet/js/jquery-ui-1.8.5.custom.min.js" typ 阅读全文

posted @ 2011-03-03 14:31 奔腾年代 阅读(438) 评论(0) 推荐(0) 编辑

省市级联

摘要: <script src="http://www.cnblogs.com/JS/jquery-ui-1.8.5.SouthStreet/js/jquery-1.4.2.min.js"type="text/javascript"></script><script type="text/javascript"> function changeshen(shen) { document.getElementById("drpshi").length = 0; $.getJSON(&quo 阅读全文

posted @ 2011-03-03 14:27 奔腾年代 阅读(238) 评论(0) 推荐(0) 编辑

在asp:Repeater中的asp:LinkButton中按Id删除对应行的数据时用asp:Repeater的ItemCommand方法

摘要: <asp:LinkButton ID="lbtnDelete" runat="server" CommandName="delete" CommandArgument='<%#((IMDMSP.MODEL.Help)Container.DataItem).Id %>'>删除</asp:LinkButton> protected void _rptSource_ItemCommand(object source, RepeaterCommandEventArgs e) { if (e. 阅读全文

posted @ 2011-03-03 09:09 奔腾年代 阅读(646) 评论(0) 推荐(0) 编辑

在asp:Repeater中的label中分类绑定值时用asp:Repeater的ItemDataBound方法

摘要: using System.Web.UI.HtmlControls; protected void _rptSource_ItemDataBound(object sender, RepeaterItemEventArgs e) { if (e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem) { /*绑定ItemTemplete时的操作*/ HtmlGenericControl label = (HtmlGenericControl)e.Item.FindControl( 阅读全文

posted @ 2011-03-03 08:57 奔腾年代 阅读(423) 评论(0) 推荐(0) 编辑