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

Default Grid to 1st 50 rows

2 Answers 215 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Kevin
Top achievements
Rank 1
Kevin asked on 20 Jun 2013, 02:11 PM
How can I defualt my grid to show the 1st 50 rows.  I have basic paging turned on, and the users have requested that the grid defualt to 50 rows instead of them having to pick the 50 option in the paging.  Some of the grid don't have 50 rows however and in this case they just want to show all.


<telerik:RadGrid ID="myRadGrid" runat="server" Width="100%" Skin="Web20">
                                                                   <MasterTableView AutoGenerateColumns="false" Font-Size="10" DataKeyNames="intScheduleId" CommandItemDisplay="Top" AllowPaging="true" AllowSorting="true">
                                                                       <HeaderStyle ForeColor="White" Font-Bold="true" HorizontalAlign="Center" />
                                                                       <ItemStyle HorizontalAlign="Center"/>
                                                                       <AlternatingItemStyle BackColor="#B0C4DE"  HorizontalAlign="Center" />
                                                                       <PagerStyle AlwaysVisible="true"  Mode="NextPrevAndNumeric" />
                                                                       <CommandItemStyle Height="25px" Font-Bold="true" Font-Underline="true" HorizontalAlign="Left" VerticalAlign="Bottom" />


2 Answers, 1 is accepted

Sort by
0
Accepted
Princy
Top achievements
Rank 2
answered on 20 Jun 2013, 02:27 PM
Hi Kevin,

I guess you want the page to show 50 records each time rather than 10.Please set PageSize=50 in the radgrid.
You can set it programatically also as RadGrid1.PageSize=50.

Thanks,
Princy
0
Kevin
Top achievements
Rank 1
answered on 20 Jun 2013, 02:37 PM
hi,

Thanks easier than I thought.
Tags
Grid
Asked by
Kevin
Top achievements
Rank 1
Answers by
Princy
Top achievements
Rank 2
Kevin
Top achievements
Rank 1
Share this question
or