2014年1月18日

AspNetPager 的使用

摘要: 下面选用的是新闻发布系统里用的代码。SQL 存储过程:CREATE PROCEDURE procNewsSelectByPager @startRecordIndex int, @endRecordIndex intASBEGIN select * from (select row_number() over (order by id) as row, * from news) temp where temp.row between @startRecordIndex and @endRecordIndexENDGO数据访问层://SQLHelperpublic ... 阅读全文

posted @ 2014-01-18 23:40 Error503 阅读(249) 评论(0) 推荐(0) 编辑

2014年1月6日

.NET中获取字符串的MD5码

摘要: C# 代码:导入命名空间(需要在Web页面的代码页中引用) using System.Web.Security;获取MD5码string Password = FormsAuthentication.HashPasswordForStoringInConfigFile(TextBox1.Text.ToString(), "MD5"); 阅读全文

posted @ 2014-01-06 11:12 Error503 阅读(92) 评论(0) 推荐(0) 编辑

.NET在后置代码中输入JS提示语句(背景不会变白)

摘要: C# 代码:Page.ClientScript.RegisterStartupScript(Page.GetType(), "message", ""); 阅读全文

posted @ 2014-01-06 11:09 Error503 阅读(95) 评论(0) 推荐(0) 编辑

.NET使用一般处理程序生成验证码!

摘要: C# 代码:using System;using System.Web;using System.Drawing;using System.Drawing.Drawing2D;using System.Web.SessionState; public class Verification: IHttpHandler, IRequiresSessionState // 要使用session必须实现该接口,记得要导入System.Web.SessionState命名空间{ public void ProcessRequest(HttpCon... 阅读全文

posted @ 2014-01-06 11:05 Error503 阅读(137) 评论(0) 推荐(0) 编辑

导航