User Experience Stack Exchange is a question and answer site for user experience researchers and experts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

In my WinForms application there is a ComboBox with default values. The user should be able to add items to the ComboBox or rename existing items.

I want the design to be simplistic. This was my initial approach:

  • If the user types something in to the ComboBox and hits enter and the item exists, select it. If the item does not exist, add it.

  • If the the ComboBox is empty when the user hits enter, delete the item at the current index.

This worked alright, except for these two problems:

  1. Because it was a custom user interface control, the functionality is not intuitive.

  2. If the user deletes an item from the ComboBox and there are items after it, their indices are adjusted accordingly. Basically, every item index after that item is bumped down 1. This is bad because once an item is added, its index should not be changed as other services may depend on it. Essentially, items should not be allowed to be removed. Only renamed. Possibly to blank if they are no longer needed.

The only real solution I can think of is to have a separate dialog but I cannot envision a proper design of one.

Here's an example for the first implementation one would think of:

  1. Have a menu item open up a dialog with the purpose to add or rename items of the ComboBox.

  2. Have a TextBox for every item in the ComboBox in this dialog window. If the last TextBox is not empty, add another one (or have a button to add another TextBox).

I suppose this approach is fine, but I don't like it for a couple reasons.

  1. If the user has a lot of items in the ComboBox, the dialog window would be huge or require a scroll bar.

  2. This approach requires a menu item, a corresponding dialog window, and a potential large amount of dynamic controls.

I've been trying to think of a better way to approach this but I am not having any luck.

share|improve this question
You should never ever have anything depend on the position of something else in a list. Learn how to use a combination of value (identifier) and display text (what the user sees) for each item in comboboxes and the like. Users can then re-order and delete items to their hearts desire. They will only affect the index of items, but won't affect their display test or their identifying values. It will save you (and people using your work) numerous headaches. – Marjan Venema Sep 9 '11 at 8:12
up vote 0 down vote accepted

It seams you are using ComboBox for that it have not been created. ComboBox stores a fixed list of items to select. If you need to edit this list, use separated form to edit items. It would be more intuitive, trust. Otherwise, please, use grid, for example. It is more "editable".

share|improve this answer

What you are looking for is (I think) an auto complete text box.

This allows the user to add any text at all, but matches the input against a predefined list and then allows the user to select one of the items from that list. You might see this where the user has to enter a state or country.

In your case you want to add any input that isn't already on the list to the list - which is possible.

Your requirement to delete is also possible - but note that in Outlook which has similar functionality when entering e-mail recipients it uses Shift+Delete to remove items.

This blog post has an example of how to create one in WinForms. I won't repeat the code here as it's not necessary.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.