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

[Solved] Grid PagerStyle-Mode="" Issues

3 Answers 76 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jay
Top achievements
Rank 1
Jay asked on 27 Apr 2009, 02:29 PM
PagerStyle-Mode="NextPrevNumericAndAdvanced"
The Page Size textbox only is wide enough for 1 number. If there are 10 or more pages the textbox is not big enough.
How can I make the textboxes for this style larger?
J.

3 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 27 Apr 2009, 03:25 PM
Hello Jason,

The size of the aforementioned textbox is calculated automatically depending on the item count.
I attached a simplified demo which illustrates this behavior.

Kind regards,
Daniel
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Jay
Top achievements
Rank 1
answered on 27 Apr 2009, 05:01 PM
I think I must not have explained my problem correctly.
I am speaking of the textbox that displays the number of records per page in the pager control on the bottom of the grid. The textbox is only wide enough for #'s 1-9, the text box literally looks like it's 20 pixels wide so it can't display 10 or higher.
Thanks, J.
0
Princy
Top achievements
Rank 2
answered on 28 Apr 2009, 05:04 AM
Hello Jason,

You can try out the following code to access the numeric textboxes in the Pager row and increase its width:
c#:
 protected void RadGrid1_ItemDataBound (object sender, GridItemEventArgs e) 
    { 
       if (e.Item is GridPagerItem) 
        { 
            GridPagerItem pager = (GridPagerItem)e.Item; 
            ((RadNumericTextBox)pager.FindControl("ChangePageSizeTextBox")).Width = Unit.Pixel(30); 
            ((RadNumericTextBox)pager.FindControl("GoToPageTextBox")).Width = Unit.Pixel(30); 
        } 
     } 

Thanks
Princy.
Tags
Grid
Asked by
Jay
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Jay
Top achievements
Rank 1
Princy
Top achievements
Rank 2
Share this question
or