Selecting null in a filtering Select

How do I select the null-item in a filtering Select without the mouse?

I have a Select that has hundreds of items, and it is pre-selected into one of them. I would like to change its value to null. If I just delete the text in the select and tab away, it seems as if the Select never fires an ValueChangeEvent. If I scroll all the way up to the beginning of the list, and select the empty item (null item), the value changes as expected. The problem is, as the Select can have hundreds of items, it’s inconvenient to click many times, perhaps tens of times, to get all the way to the top of the list.

Is there a way to get the behavior I want to, or do I need a separate “clear” button of some sort?

Works form me - of course a chance I misunderstood - see if this works as expected: http://toolkit.itmill.com/demo/sampler/#Components/Selects/ComboBoxNewItems

Best Regards,
Marc

I think you understood it correctly, and Sampler shows exactly how it should behave. But I’m getting weird results:

If my Selected is not pre-selected (with select.setValue(x) and select.select(x)), I get the correct behavior - value change events are sent correctly when the text entry is deleted. But if I prepopulate the values, most often my (the same) value change listener is never fired. But even this isn’t consistent…

Got it, it seems to be a bug: http://dev.vaadin.com/ticket/2986

Thanks for noticing!

//Marc