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

Scroll and text nowrap on dropdown

3 Answers 106 Views
ToolBar
This is a migrated thread and some comments may be shown as answers.
Eduardo
Top achievements
Rank 1
Eduardo asked on 31 Jul 2009, 01:37 AM
Hi,

I have two questions on the drop down menu. First one should be easier, do you have an EnableAutoScroll as in the RadMenu? I have a drop down that can go beyond the window limits and it would be very useful to have the scroll as there is in the menu.

The second one is a bit more complicated. My drop down is constructed on the client side, and it is based on adding items. However, I noticed that whenever I add first a short text item then a long text item, the long text gets wrapped into two lines or cutoff if I use nowrap. Is there a way to adjust the width of the drop down menu to fit all item texts?

Thanks,
Eduardo

3 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 03 Aug 2009, 09:11 AM
Hello Eduardo,

Scrolling of the dropdown items can be achieved by setting the DropDownHeight property. For example:

<telerik:RadToolBarDropDown runat="server" DropDownHeight="200px" Text="DropDown 0">

The second problem turned out to be a bug with RadToolBar. I have logged it and we will try to fix it shortly.



Peter
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
Dasha
Top achievements
Rank 1
answered on 17 Jan 2012, 11:02 PM
Hello Peter,

Looks like we ran into the same problem with the ToolBarSplitButton: is a short-text item is added first, the long-text item added afterwards gets wrapped.  Just wondering if this is still a bug or if there's a fix that I can apply.

Thank you very much,

Dasha.
0
Peter
Telerik team
answered on 19 Jan 2012, 12:40 PM
Hi Dasha,

You can use jQuery to set the width for items with longer text:
$telerik.$(newButton.get_element()).width(400);
 $telerik.$(newButton.get_element()).closest(".RadToolBarDropDown").width(420);


Greetings,
Peter
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now
Tags
ToolBar
Asked by
Eduardo
Top achievements
Rank 1
Answers by
Peter
Telerik team
Dasha
Top achievements
Rank 1
Share this question
or