COMBOBOXITEM TO BE REPLACED BY TEXTBOX ON CLICKING

Samuel Fernandes

Total Post:159

Points:1117
Posted by  Samuel Fernandes
C#
 1080  View(s)
Ratings:
Rate this:

I am implementing a comboBox consisting of normal comboBoxItems and those which will allow the modification of the list bound to the comboBox.

Eg: I need the following to go into the comboBox - option1, option2, option3, AddNewOption where, upon clicking on the AddNewOption, I want the comboBoxItem to expose a textBox where I enter the content, which will be dynamically added to the list bound to the comboBox.

How do I implement the highlighted portion?

  1. Sumit Kesarwani

    Post:378

    Points:2694
    Re: Comboboxitem to be replaced by textbox on clicking

    Hi Samuel,


    I would probably bind to an editable collection view that adds the NewItemPlaceholder at the end, then one could define a DataTemplate for the place-holder which contains the outlined logic.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!