摘要:
usingSystem;usingSystem.Text;usingSystem.Security.Cryptography;usingSystem.IO;//默认密钥向量privatestaticbyte[]Keys={0x12,0x34,0x56,0x78,0x90,0xAB,0xCD,0xEF};///<summary>///DES加密字符串///</summary>///<paramname="encryptString">待加密的字符串</param>///<paramname="encryptKey 阅读全文
posted @ 2011-04-19 13:00
狼-志
阅读(408)
评论(0)
推荐(0)
摘要:
自己测试用的代码Declare @ID int Declare @MoveRecords int Declare @CurrentPage int Declare @PageSize int set @CurrentPage=1set @PageSize=2--@CurrentPage和@PageSize是传入参数 Set @MoveRecords=@CurrentPage * @PageSize+1 --下面两行实现快速滚动到我们要取的数据的行,并把ID记录下来 Set Rowcount @MoveRecords Select @ID=id from [Table] Order by idS 阅读全文
posted @ 2011-04-19 10:59
狼-志
阅读(3417)
评论(0)
推荐(1)
摘要:
GridView数据导入Excel/Excel数据读入GridView效果图:解决方案:页面增加一个按钮,单击事件添加如下方法:protected void Button1_Click(object sender, EventArgs e) { Export("application/ms-excel", "学生成绩报表.xls"); } private void Export(string FileType, string FileName) { Response.Charset = "GB2312"; Response.Conte 阅读全文
posted @ 2011-04-19 09:30
狼-志
阅读(342)
评论(0)
推荐(0)
摘要:
要点:1.不能是自动列,必须是手动列。;2.后台必须绑定主键,否则在进行操作时获取不到主键 GridView1.DataKeyNames = new string[] { "userid" };//主键3. 展示列用,可以实现编辑<asp:BoundField DataField="username" HeaderText="用户姓名" />,编辑列<asp:CommandField HeaderText="编辑" ShowEditButton="true" />;4.后 阅读全文
posted @ 2011-04-19 09:20
狼-志
阅读(2805)
评论(0)
推荐(0)

浙公网安备 33010602011771号