472,353 Members | 2,134 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,353 software developers and data experts.

DataGrid Pagination

I am trying to get pagination working on a datagrid. Can anyone point me to
a resource for help on this? I'm not sure if custom paging is the best
option or not.
Nov 17 '05 #1
3 8588
hi,
I posted a similar post below.
datagrid does paging for you, u just set AllowPaging=true for datagrid.
it's said that custom paging is not paging at all, no page index appeared
at the bottom if you use custom paging.

what kind of datasource u r using for datagrid control,it seems that
matters
too.

Yangtsi.

"Joseph D. DeJohn" <jo********@hotmail.com> 写入消息新闻
:Oz**************@TK2MSFTNGP12.phx.gbl...
I am trying to get pagination working on a datagrid. Can anyone point me to a resource for help on this? I'm not sure if custom paging is the best
option or not.

Nov 17 '05 #2
I saw your post, but the default pagination is having problems working. I
opted for the only other alternative. You can guess. I am using a SQL
datasource. Can't believe you are having problems with custom paging also.
Dunno what to think at this point.

"Yangtsi River" <na***@sina.com> wrote in message
news:eR**************@TK2MSFTNGP10.phx.gbl...
hi,
I posted a similar post below.
datagrid does paging for you, u just set AllowPaging=true for datagrid.
it's said that custom paging is not paging at all, no page index appeared
at the bottom if you use custom paging.

what kind of datasource u r using for datagrid control,it seems that
matters
too.

Yangtsi.

"Joseph D. DeJohn" <jo********@hotmail.com> 写入消息新闻
:Oz**************@TK2MSFTNGP12.phx.gbl...
I am trying to get pagination working on a datagrid. Can anyone point
me to
a resource for help on this? I'm not sure if custom paging is the best
option or not.


Nov 17 '05 #3
allowpaging passes control to the datagrid to take care of most of it, all
it means is the control divides up the page according to your page count,
you still have to instantiate a post back procedure that handles switching
to the different pages...

custom pages does work, but it doesn't split the pages up for you, you've
more control, and hence have to do more work with the control to get the
results you want... (you may want all the records in may 2000 in one page,
for example, and there may be more in june, so a straight count that the
allowpaging uses wouldn't work...)

the postback method is easy enough.

Sub MyDBgrid_Paging(sender As Object, e As DataGridPageChangedEventArgs)
MyDBgrid.CurrentPageIndex = e.NewPageIndex
BindData()
End Sub
this simply gets the number that was clicked on from 'e', then tell the grid
what page it's on before binding the data.

good luck
"Joseph D. DeJohn" <jo********@hotmail.com> wrote in message
news:e5**************@TK2MSFTNGP12.phx.gbl...
I saw your post, but the default pagination is having problems working. I
opted for the only other alternative. You can guess. I am using a SQL
datasource. Can't believe you are having problems with custom paging also. Dunno what to think at this point.

"Yangtsi River" <na***@sina.com> wrote in message
news:eR**************@TK2MSFTNGP10.phx.gbl...
hi,
I posted a similar post below.
datagrid does paging for you, u just set AllowPaging=true for datagrid.
it's said that custom paging is not paging at all, no page index appeared at the bottom if you use custom paging.

what kind of datasource u r using for datagrid control,it seems that
matters
too.

Yangtsi.

"Joseph D. DeJohn" <jo********@hotmail.com> 写入消息新闻
:Oz**************@TK2MSFTNGP12.phx.gbl...
I am trying to get pagination working on a datagrid. Can anyone point

me
to
a resource for help on this? I'm not sure if custom paging is the best option or not.



Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Mukesh Kumar | last post by:
Hi, Can anybody throw some light about displaying records in datagrid and pagination will be done alphabetically. Like I want to click on G and...
1
by: David Petersen | last post by:
I need to change the paging buttons in my C# web datagrid from "previous" and "next" to something like "Records 10-20 of 100", etc., depending on...
0
by: Child | last post by:
I have a datagrid on which i would like a button column and pagination in the asp:datagrid tag i have the following code: ...
2
by: RB | last post by:
Hi All, The ASP.NET Datagrid's pagination capability allows me to display either the Next/Prev buttons or the Page numbers to allow the user to...
1
by: Khan.A.Mushtaq | last post by:
hi can any one help me how to make working page number, edit and delete when we use datagrid on a web application in vb.net 2003. I have made...
0
by: harish.c27 | last post by:
Hi folks!!! Can we implement pagination for DataGrid control in a Windows Forms (.net1.0- 2003) Application? Any code help will be useful. ...
1
by: OceanBreeze | last post by:
I am new to .Net. I am using ASP 2.0 and C#. I want to pupolate a data grid programatically using the values obtained from a list conating domain...
2
by: =?Utf-8?B?SnVsaWEgQg==?= | last post by:
Hi all Got a weird problem with pagination on a datagrid in asp.net 1.1. It's populated depending on user selected criteria (it either...
16
by: gnawz | last post by:
I have a pagination function I am using in a file called functions.php as below<? //Pagination functions function getPagingQuery($sql, $itemPerPage...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: antdb | last post by:
Ⅰ. Advantage of AntDB: hyper-convergence + streaming processing engine In the overall architecture, a new "hyper-convergence" concept was...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Matthew3360 | last post by:
Hi, I have been trying to connect to a local host using php curl. But I am finding it hard to do this. I am doing the curl get request from my web...
0
Oralloy
by: Oralloy | last post by:
Hello Folks, I am trying to hook up a CPU which I designed using SystemC to I/O pins on an FPGA. My problem (spelled failure) is with the...
0
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand....
0
BLUEPANDA
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS...
0
by: Rahul1995seven | last post by:
Introduction: In the realm of programming languages, Python has emerged as a powerhouse. With its simplicity, versatility, and robustness, Python...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.