473,657 Members | 2,409 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

paging in datagrid

I using datagrid to display user's login/out history on my web site, also I have
set AllowPaging on the datagrid to true, but not matter I clicked page number on
either top or bottom, it is still display first page. Do I did something wrong?
Thanks in advance.
Nov 19 '05 #1
3 911

"Jason" <j@NoSpamPlease .org> wrote in message
news:2b******** *************** *********@4ax.c om...
I using datagrid to display user's login/out history on my web site, also I have set AllowPaging on the datagrid to true, but not matter I clicked page number on either top or bottom, it is still display first page. Do I did something wrong? Thanks in advance.


Allow paging only raises the event. You need to handle the click. There are
quite a few posts on this.
Nov 19 '05 #2
You need to handle the PageIndexChange d event, fetch the new page of data,
and rebind the grid.

-Brock
DevelopMentor
http://staff.develop.com/ballen
I using datagrid to display user's login/out history on my web site,
also I have set AllowPaging on the datagrid to true, but not matter I
clicked page number on either top or bottom, it is still display first
page. Do I did something wrong? Thanks in advance.


Nov 19 '05 #3
you have to write code to handle the PageIndexChange d event
"Jason" <j@NoSpamPlease .org> wrote in message
news:2b******** *************** *********@4ax.c om...
I using datagrid to display user's login/out history on my web site, also I have set AllowPaging on the datagrid to true, but not matter I clicked page number on either top or bottom, it is still display first page. Do I did something wrong? Thanks in advance.

Nov 19 '05 #4

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

Similar topics

0
1073
by: Joseph Walrave | last post by:
I want to create an ASP.NET web application using C#. Purpose of the web application is access to a MS SQL Server database. Some of our customers are using large databases, so the application should be able to handle large datasets in a proper and user-friendly way. I want to use a DataGrid. I also want to use the option Custom Paging. I already succeeded with using a stored procedure (adjusted downloaded code from the internet) to use...
2
3568
by: RelaxoRy | last post by:
sqlConnection1.Open(); myReader = sqlCommand1.ExecuteReader(); DataGrid1.DataSource = myReader; DataGrid1.DataBind(); myReader.Close(); sqlConnection1.Close(); The Datagrid populates fine. I'm styling it on the HTML page. I configure the DataGrid for paging through the property builder fine. I AllowCustomePaging=true;. The page loads fine but it only shows "1"
1
4151
by: iforsyth | last post by:
Have a paging datagrid with a checkbox control in column(0). ViewState is enabled. I check the checkbox in first row of the grid on a page and then the program hits this event: Private Sub dgRegGrid_PageIndexChanged(ByVal source As Object, ByVal e As System.Web.UI.WebControls.DataGridPageChangedEventArgs) Handles dgRegGrid.PageIndexChanged I then do a loop to check the checkbox state.
2
2236
by: Max | last post by:
Is it possible or more effecient to use a stored procedure to populate a datagrid when using datagrid or custom paging? Is it (ADO.NET?) pulling the entire table into the dataset or is it just pulling the page as defined by the page size? I'm assuming that if I use a stored procedure with a datagrid, I won't be able to use the datagrid's paging anyway, and would have to create my own code in the stored procedure to return each page of...
1
1981
by: Maziar Aflatoun | last post by:
Hi, I have a Datagrid with AllowPaing property set so that the two arrows for the next and previous set of rows are showing. This is working fine. Now is there a way to instead of the 2 default previous/next arrows to use images to represent this previous and next property of the DataGrid? Thank you Maziar A.
0
1181
by: Jos Walrave | last post by:
I want to create an ASP.NET web application using C#. Purpose of the web application is access to a MS SQL Server database. Some of our customers are using large databases, so the application should be able to handle large datasets in a proper and user-friendly way. I want to use a DataGrid. I also want to use the option Custom Paging. I already succeeded with using a stored procedure (adjusted downloaded code from the internet) to use...
0
944
by: Roger | last post by:
I have some code that uses a SQL Stored procedure to return some rows. I would then like to have these rows show up in a datagrid. sqlCmd = New SqlClient.SqlCommand("R_GetSiphonDetail", sCon) sqlCmd.CommandType = CommandType.StoredProcedure rdr = sqlCmd.ExecuteReader(CommandBehavior.Default) DataGrid1.DataSource = rdr DataGrid1.DataBind() This works just fine as long as I don't turn on paging.
3
1446
by: Darren | last post by:
Dear Groups I've used paging with a datagrid in C# at least a hundred times, but for whatever reason, I cannot get the prev /next to appear as links. It is absolutely certain that the number of records exceed the page size. Code is as follows: <asp:datagrid id="grdStores" runat="server" allowpaging="True"
3
2239
by: Antonio | last post by:
I am having a problem finding out how to page a datagrid. I have the procedure for moving from page to page as: private void changePage(object source, System.Web.UI.WebControls.DataGridPageChangedEventArgs e) { dgCustInfo.CurrentPageIndex = e.NewPageIndex; --connection information and SELECT statement here not in a separate procedure--
0
886
by: =?Utf-8?B?cGF0YW4uYW5pZkBnbWFpbC5jb20=?= | last post by:
Hi, My requirement is paging datagrid columns. not row paging Actually i have 18 columns at runtime..first 6 columns display at first time and remaining 6 will display by clicking next button and so on.... "Need urgent help" "Thanks in Advance"
0
8395
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8826
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8732
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8503
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6166
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5632
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4306
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2726
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1955
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.