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

Change AutoComplete Drop Down Width

1 Answer 274 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
C
Top achievements
Rank 1
C asked on 19 Jun 2012, 12:09 AM
Is it possible to change the width of the drop down. Right now I have a text box that is about 100 pixels wide. The drop down that slides down is exactly the same size. However, the autocomplete results come back with both a code and a description. Each item in the drop down is wrapped across 2 to 3 lines. I would prefer to have each item to fit on one line (roughly 300 pixels wide). I adjusted the template to ensure each item had a width of 300 pixels, but all that did was put a horizontal scroll bar in the drop down.

I suspect it is not possible out of the box since there isn't any documentation on doing so. It also appears that the drop down is wrapped in a div that had its width set through JavaScript. Nonetheless, has anyone successfully implemented this?

1 Answer, 1 is accepted

Sort by
0
Cyndie
Top achievements
Rank 1
answered on 29 Jun 2012, 02:39 PM
This css worked for me:

#divname .k-autocomplete{
 width: 300px;
}
Tags
AutoComplete
Asked by
C
Top achievements
Rank 1
Answers by
Cyndie
Top achievements
Rank 1
Share this question
or