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

DropDownList Popup Width

6 Answers 247 Views
DropDownList
This is a migrated thread and some comments may be shown as answers.
Roberto Wenzel
Top achievements
Rank 2
Roberto Wenzel asked on 06 Feb 2011, 03:02 PM
Hello,
I am trying to solve this simply soundling problem for hour now. I am trying to adjust the minimum width of the popup of a DropDownList.

I tried something like 
rddl_Consignor_Iso.Popup.MinimumSize = New Size(500, 200)
or 
rddl_Consignor_Iso.DropDownListElement.DropDownMinSize = New Size(500, 200)
or
rddl_Consignor_Iso.DropDownMinSize = New Size(500, 200)
and some other coding.
All worked fine, when using the arrow button with the mouse. The popup then is in the expected width. But when entering the box using the keyboard and typing some letters, the box pops up only in the same width as the DropDownList control. I'm getting mad on this. Which value do I have to set to get an acceptable result? Cheers Roberto

6 Answers, 1 is accepted

Sort by
0
Accepted
Richard Slade
Top achievements
Rank 2
answered on 07 Feb 2011, 03:22 PM
Hello Roberto,

The following code should help you

' set the auto complete suggest
Me.RadDropDownList2.AutoCompleteMode = AutoCompleteMode.Suggest
' set the min size of the drop down
RadDropDownList2.DropDownListElement.DropDownMinSize = New Size(275, 0)
' and the size of the auto complete drop down
RadDropDownList2.DropDownListElement.AutoCompleteSuggest.DropDownList.DropDownMinSize = New Size(275, 0)

Let me know if you need further help
Richard
0
Roberto Wenzel
Top achievements
Rank 2
answered on 07 Feb 2011, 05:53 PM
Thanks a lot Richard!
Especially the last line of code is what I was looking for.
Obviously I didn't dig deep enough -;)
Cheers Roberto
0
Richard Slade
Top achievements
Rank 2
answered on 07 Feb 2011, 06:00 PM
You're welcome. glad it helped.
Richard
0
Clive
Top achievements
Rank 1
answered on 17 Nov 2011, 08:07 AM
Thanks, helped me too.

I originally tried using the  DropDownWidth property. that didn't work, then I tried the Popup.Width property. That worked when you used the drop down arrow with the mouse, but not for keyboard entry. Interesting that there are multiple popups for the drop down.. makes sense when you think about it, but not obvious enough for me as a user :)

 

0
Peter
Telerik team
answered on 18 Nov 2011, 10:50 AM
Hi Clive,

Thank you for writing.

It is normal to see both popups and this behavior is by design. We are following the behavior of the standard Microsoft ComboBox. You could apply the solution provided by Richard.

I hope this helps.

Regards,
Peter
the Telerik team

Q2’11 SP1 of RadControls for WinForms is available for download (see what's new); also available is the Q3'11 Roadmap for Telerik Windows Forms controls.

0
Aaron
Top achievements
Rank 1
answered on 09 Jan 2012, 10:54 PM
This thread helped me with the same issue. I was setting the RadDropDownList.Popup.Width. 

I assumed that there must be some other list object that was being used when autoSuggest was happening I just was unable to figure out what the object was through the standard documentation. 

Thanks.
Tags
DropDownList
Asked by
Roberto Wenzel
Top achievements
Rank 2
Answers by
Richard Slade
Top achievements
Rank 2
Roberto Wenzel
Top achievements
Rank 2
Clive
Top achievements
Rank 1
Peter
Telerik team
Aaron
Top achievements
Rank 1
Share this question
or