投票系统分享(4)
来源:未知 责任编辑:责任编辑 发表时间:2015-03-01 01:47 点击:次
98 {
99 if(item .Selected )
100 {
101 cmd.CommandText ="update VoteItem set Number=Number+1 where ItemID="+item.Value.ToString ();
102 cmd.ExecuteNonQuery ();
103 }
104 }
105 Response .Cookies ["pass"].Value ="pass";
106 Response .Cookies ["pass"].Expires =DateTime .Now.AddDays (1);
107 Response .Write ("<script language='javascript'>alert('投票成功');history.back();</script>");
108
109 }
110
111
112 }
113 else
114 {
115 RadioButtonList rb=(RadioButtonList )Panel1 .FindControl ("listVoteItem");
116 if(rb.SelectedIndex ==-1)
117 {
118 Response .Write ("<script language='javascript'>alert('你必须至少选择一票');history.back();</script>");
119 Response .End ();
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 进入详细评论页>>
今日头条
更多>>您可能感兴趣的文章
- Web Service学习笔记(4)
- asp.net DataTable和Dataset序列化成Json格式
- .NET简谈互操作(四:基础知识之Dispose非托管内存
- 聊聊.net程序设计——浅谈使用VS2010建模拓展(下
- .net架构的最后思考(箴言)
- JQuery+Asp.net MVC实现用户名重名查询
- 使用ASP.NET MVC3+EF+Jquery制作文字直播系统(四
- .NET设计模式:工厂方法模式(Factory Method)[1]
- MVC3+Entity Framework 实现投票系统(二)
- Spring MVC 3.0.5+Spring 3.0.5+MyBatis3.0.4全注



