How to create a Paging navigation in a datagrid?

  • Thread starter stanley mroczek
  • Start date
S

stanley mroczek

Hello,

I created a data grid which 500 records .


Now i need to create the navigation. Something like:

Previous [Current Page] of [Total Pages] Next

Can someone help me out?

Thank you,
stan
 
R

Raghu Raman

Hi freind,

It is very simple.Just set the right click the grid and set the

Allowcustompaging=false;
Allowpaging =true;
and in u r code, set

dgrid.datasource=dset.tables["t1"].defaultview.
dgrid.databind().

The default itself tells the grid to to take care of the pagins.


With Regards
Raghu
 
R

rosh

the paging naviagtion is fine but could you help me with the format i
want it to be displayed in?
i want the paging to be displayed as follows:
<PREVIOUS[text box editable][total records][GO button]NEXT>
The functionality is:
1.when i click on PREVIOUS i go to previous page(but obvious :))
2.same for NEXT
3.the TEXTBOX is provided for adding page number
4.TOTAL RECORDS display the nn editable text with total number of
records.
5. the GO button when clicked must take me to the page provided by user
in the TEXTBOX.

is such sort of thing possible in datagrid paging?can i add textbox and
Buttons from my code behind in the PAGER aprt of DataGrid?
can anyone help me out with the same
thnkx


cheers
 
R

rosh

hi friend,
thankx for ur reply but all u told was about how do i do paging in
DataGrid ....my rpoblem is different :(
let me explain it to u:

the format i want it to be displayed is:
i want the paging to be displayed as follows:
<PREVIOUS[text box editable][total records][GO button]NEXT>
The functionality is:
1.when i click on PREVIOUS i go to previous page(but obvious :))
2.same for NEXT
3.the TEXTBOX is provided for adding page number
4.TOTAL RECORDS display the nn editable text with total number of
records.
5. the GO button when clicked must take me to the page provided by user
in the TEXTBOX.

I hope you got my problem.if not please ask me ,i can elaborete more on
it
kindly help me
thnkx
cheers
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,020
Latest member
GenesisGai

Latest Threads

Top