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

Dropdown text width inside a grid

1 Answer 64 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Raja
Top achievements
Rank 1
Raja asked on 28 Dec 2015, 06:25 PM

I have a dropdown inside a grid which currently takes 100% width of the column. Because of number of columns, width of this column is very less compared to the length of each item I have for the dropdown.

I want to make the options list of the dropdown to display full text in single line with out increasing the width of the column. I am using white-space:nowrap to get the text in online but the options list gets  scroll bar. Is there a way that I can increase its width to 100%?

1 Answer, 1 is accepted

Sort by
0
Iliana Dyankova
Telerik team
answered on 04 Jan 2016, 08:00 AM
Hi Raja,

Apologies for the delayed reply.

For this scenario I would suggest increasing the DropDownList list width. 
// get reference to the DropDownList
var dropdownlist = $("#ddlId").data("kendoDropDownList");
// set width of the DropDownList
dropdownlist.list.width(500);
For your convenience here is a basic dojo.

Regards,
Iliana Nikolova
Telerik
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 Feedback Portal and vote to affect the priority of the items
Tags
Grid
Asked by
Raja
Top achievements
Rank 1
Answers by
Iliana Dyankova
Telerik team
Share this question
or