gridview分页
protected void lnkbtnFrist_Click(object sender, EventArgs e)
{
//首页
this.GridView_username.PageIndex = ;
this.ReadData();
}
protected void lnkbtnPre_Click(object sender, EventArgs e)
{
//上一页
if (this.GridView_username.PageIndex > )
{
this.GridView_username.PageIndex = this.GridView_username.PageIndex - ;
this.ReadData();
}
}
protected void lnkbtnNext_Click(object sender, EventArgs e)
{
//下一页
if (this.GridView_username.PageIndex < this.GridView_username.PageCount)
{
this.GridView_username.PageIndex = this.GridView_username.PageIndex + ;
this.ReadData();
}
}
protected void lnkbtnLast_Click(object sender, EventArgs e)
{
//最后一页
this.GridView_username.PageIndex = this.GridView_username.PageCount;
this.ReadData();
}
//选择所需要的页数
protected void ddlCurrentPage_SelectedIndexChanged(object sender, EventArgs e)
{
this.GridView_username.PageIndex = this.ddlCurrentPage.SelectedIndex;
this.ReadData();
}
gridview分页的更多相关文章
- asp.net gridview 分页显示不出来的问题
使用gridview分页显示,在点击第二页的时候显示空白,无数据. 原因是页面刷新,绑定datatable未执行 解决方法: 1.将datatable设置为静态 2.在OnPageIndexChang ...
- Android GridView 分页加载数据
android UI 往右滑动,滑动到最后一页就自动加载数据并显示 如图: package cn.anycall.ju; import java.util.ArrayList; import java ...
- GridView 分页方法
要实现GrdView分页的功能. 操作如下: 1.更改GrdView控件的AllowPaging属性为true. 2.更改GrdView控件的PageSize属性为 任意数值(默认为10) 3.更改G ...
- GridView分页排序
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="GridviewPage.asp ...
- GridView分页的实现
要在GridView中加入 //实现分页 AllowPaging="true" //一页数据10行 PageSize="10" // 分页时触发的事件 OnPa ...
- GridView分页功能的实现
当GridView中显示的记录很多的时候,可以通过GridView的分页功能来分页显示这些记录.如果GridView是直接绑定数据库,则很简单:将"启动分页"打勾即可. 如果是用代 ...
- GridView分页的实现 ASP.NET c#(转)特好用
要在GridView中加入 //实现分页 AllowPaging="true" //一页数据10行 PageSize="10" // 分页时触发的事件OnPag ...
- 自己写的一个ASP.NET服务器控件Repeater和GridView分页类
不墨迹,直接上代码 using System; using System.Collections.Generic; using System.Linq; using System.Text; usin ...
- GridView分页操作
1.html <PagerStyle HorizontalAlign="Center" /> <PagerTemplate> 第: <asp:Labe ...
随机推荐
- POJ 2479 Maximum sum POJ 2593 Max Sequence
d(A) = max{sum(a[s1]..a[t1]) + sum(a[s2]..a[t2]) | 1<=s1<=t1<s2<=t2<=n} 即求两个子序列和的和的最大 ...
- simple-word-Highlighter 支持网址正则表达式匹配
- Springboot + shiro 整合之Url拦截设置(转)
shiro 整合到springboot 还是比较简单的,只需要新建一个spring-shiro.xml的配置文件: <span style="font-size:14px;" ...
- UILabel基本用法
UILabel *_label = [[UILabel alloc]initWithFrame:CGRectMake(, self.view.frame.size.height*)]; _label. ...
- [HTML] Change an HTML5 input's placeholder color with CSS
We will look at what CSS selectors to use to change an HTML5 inputs placeholder color. This can diff ...
- 【42.59%】【codeforces 602A】Two Bases
time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard ou ...
- 如何编辑SDE数据库(转载)
转自原文 如何编辑SDE数据库(转载) 如何编辑SDE数据(转自ESRI中国社区) (2008-12-15 17:26:41) 很多刚入门的朋友对SDE数据并不太了解,接二连三的在社区里面发问,有时也 ...
- Visual Stdio 环境下使用 GSL (GNU Scientific Library)
Visual Stdio 环境下使用 GSL (GNU Scientific Library) 经測试.这里的方法不适用于VS2015. * 这篇文章有点过时了.建议从以下网址下载能够在 vs 环境下 ...
- [Django] Auth django app with rest api
First, start the env: . bin/activate Then cd to our module cd djangular Create a new app: python man ...
- [RxJS] Split an RxJS observable with window
Mapping the values of an observable to many inner observables is not the only way to create a higher ...