none
Opening a specific node in a TreeView RRS feed

  • Question

  • Hello All.

    Again thanking all the help you have given me all this time in this forum.

    I want to say that I do not speak English (this is a translation)
    Let me explain my need:

    I have a TreeView and I want a parameter depending on me to some node deployment. For example:

    The TreeView control is a tree of regions, where there is a country, states, cities and areas. What I do is this:

    When selecting a comboBox of countries I deploy only U.S. states in the tree and when you select another ComboBox States of that country

    I deployed the cities of the state and so on to the areas of a city. How would I do that?

    Saludos, Solph.

    Tuesday, December 11, 2012 11:08 PM

Answers

  • Hi Solp,

    Welcome to the MSDN forum.

    Personally, I will suggest you use combobox alone.

    The Listview is useless. And only use combobox will reach all the requirements. The selected items in combobox will record the information and the choose items will also showed in the listview of combobox.

    Apart from this, there is no visible property for TreeNode to use in your application. You need to remove all nodes after one combobox selected. Once combobox selected item changed, you will need to load all nodes in the treeview back and re-do the remove action. It will influence the performance of the application.  

    Hope this helps.


    Mark Liu-lxf
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Solp Wednesday, December 12, 2012 9:40 AM
    Wednesday, December 12, 2012 8:09 AM
    Moderator

All replies

  • Hi Solp,

    Welcome to the MSDN forum.

    Personally, I will suggest you use combobox alone.

    The Listview is useless. And only use combobox will reach all the requirements. The selected items in combobox will record the information and the choose items will also showed in the listview of combobox.

    Apart from this, there is no visible property for TreeNode to use in your application. You need to remove all nodes after one combobox selected. Once combobox selected item changed, you will need to load all nodes in the treeview back and re-do the remove action. It will influence the performance of the application.  

    Hope this helps.


    Mark Liu-lxf
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Solp Wednesday, December 12, 2012 9:40 AM
    Wednesday, December 12, 2012 8:09 AM
    Moderator
  • Hi Mark Liu,

    Thanks for your help ...
    I will desist from using the Treeview ... and I will present them differently ...

    I appreciate your prompt disposal.

    regards,

    Solp.

    Saludos, Solph.

    Wednesday, December 12, 2012 9:40 AM