This is a migrated thread and some comments may be shown as answers.

Radgrid Paging Not Working

1 Answer 198 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Zach
Top achievements
Rank 1
Zach asked on 25 Oct 2010, 04:09 PM
hi guys,
I have a grid with paging mode "NextPrevAndNumeric".

The numeric and page-size-selecting work fine, however, the Next and Prev buttons doesn't work. The page refreshes but data remain the same as before.

here is my code: (dataSource is set in .cs file)

<telerik:RadGrid runat="server" id="fr_grid"
    AutoGenerateColumns = "False" GridLines="None"
    Width="99%" Height="360px" HorizontalAlign="Right" Font-Size="Small"
    AllowPaging="True" AllowSorting="True" Visible="True"
    OnDataBound="grid_data_bound" PageSize="10"
    OnItemDataBound="fr_grid_ItemDataBound">
                         
   <HeaderStyle CssClass="fr_grid_header"/>
   <ItemStyle CssClass="fr_grid_row" />
   <AlternatingItemStyle CssClass="fr_grid_alt_row" />
   <SelectedItemStyle CssClass="fr_grid_selected_row" />
   <MasterTableView Width="100%" TableLayout="auto" />
   <PagerStyle Mode="NextPrevAndNumeric" AlwaysVisible="true" />
   <ClientSettings>
    <Selecting AllowRowSelect="True"></Selecting>
    <Scrolling AllowScroll="True" SaveScrollPosition="True" ScrollHeight="350px"></Scrolling>
   </ClientSettings>
</telerik:RadGrid>

1 Answer, 1 is accepted

Sort by
0
Marin
Telerik team
answered on 26 Oct 2010, 07:29 AM
Hello Zach,

In order operations like paging, sorting and filtering to work without having additional code you need to use the NeedDataSource event to set the datasource of the grid. For more information please refer the following help article and live demo.
Otherwise, you need to handle the events manually as described here.

Kind regards,
Marin
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Grid
Asked by
Zach
Top achievements
Rank 1
Answers by
Marin
Telerik team
Share this question
or