开发者

Can a user input a free-form value into a ComboBox that is not yet in the Items collection?

开发者 https://www.devze.com 2023-02-01 20:41 出处:网络
This is probably a dumb question, but is there a way to setup a ComboBox so that a user can also add anything he wants into the ComboBox, without adding that item into Items collection? Basically,开发

This is probably a dumb question, but is there a way to setup a ComboBox so that a user can also add anything he wants into the ComboBox, without adding that item into Items collection? Basically,开发者_运维百科 much like a simple TextBox functionality, but for a ComboBox?


You can create an editable combobox by setting its DropDownStyle property to ComboBoxStyle.Simple or ComboBoxStyle.DropDown. See this MSDN page for details.

This page also has a description and comparison of all drop down list options.

0

精彩评论

暂无评论...
验证码 换一张
取 消