开发者

How to refresh (i.e. clear text from) an autocompletebox once an item has been selected?

I'm designing a Silverlight screen where I use an autocompletebox control.

One t开发者_如何学Che item 'foobar' has been selected in the autocompletebox, it's text reads 'foobar'. If a user wants to select the 'quux' value, he has to:

  1. delete the text from the control,
  2. then to type 'qu' so as to be able to select 'quux'.

Is there a way to performe the step #1 within the SelectionChanged event?

Hint: set the .text property don't work (unless it's followed by some refresh method I don't know of)


SelectionChanged is the wrong event to monitor.

Simply subscribe to the DropDownClosing event, there you'll be able to edit the .text property.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜