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

RadGrid default pagination option disappears

3 Answers 133 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Alan
Top achievements
Rank 1
Alan asked on 16 Nov 2010, 05:25 PM
Hi everyone,

     Anyone noticed that when you hard code a pagination size (in the code behind) for a radgrid widget the default page size that appears in the drop-down (mine has options 10, 15, 20 and 50, with 15 as default) disappears?
   Has anyone else noticed this?

Example:

I have options 10, 15, 20 and 50. 15 is default. They all appear.

However when I set say (in the code behind): RadGrid1.Pagesize = 50;

what now happens is that I see (when I run the code) the following options: 10, 20 and 50. i.e. 15 has disappeared!

Ques: Is this a bug??

3 Answers, 1 is accepted

Sort by
0
Vasil
Telerik team
answered on 17 Nov 2010, 10:47 AM
Hello Alan,

By default, you have predefined numbers for the page size in the pager combobox. And also the PageSize property that you can set to a custom number.
When you set the property to match with some of the default values, it is shown only once in the combobox. Because there is no sense of showing the same page size in the combo more than once. On the other hand, if the PageSize property is set to a custom value (e.g. different than 10, 20, 50), it is added as additional item in the combobox.

If you want to customize the ChangePageSize combobox, see the Shinu's post in this forum thread.

Best wishes,
Vasil
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
0
Alan
Top achievements
Rank 1
answered on 17 Nov 2010, 11:02 AM
No, I'm not implying that 50 is shown twice in the drop-down. It's not. It's displayed just once which is cool. But the old default value of 15 disappears. This is a pity as I would like it to stay as part of the options.

A.
0
Vasil
Telerik team
answered on 18 Nov 2010, 04:15 PM
Hi Alan,

After you change the custom Pagesize value with new one, the grid cannot preserve the previous custom page size. The combo box shows only default values plus your latest custom value.

All the best,
Vasil
the Telerik team
Browse the vast support resources we have to jumpstart your development with RadControls for ASP.NET AJAX. See how to integrate our AJAX controls seamlessly in SharePoint 2007/2010 visiting our common SharePoint portal.
Tags
General Discussions
Asked by
Alan
Top achievements
Rank 1
Answers by
Vasil
Telerik team
Alan
Top achievements
Rank 1
Share this question
or