Hiding a TreeView node

Discussion in 'ASP .Net' started by Shafia, May 30, 2005.

  1. Shafia

    Shafia Guest

    Hi,

    How do I hide a TreeNode programmatically? the IsVisible property of a node
    is readonly. Any suggestions?

    Thanks in Advance,
    Shafia
    Shafia, May 30, 2005
    #1
    1. Advertising

  2. Shafia

    Brock Allen Guest

    If you're talking about the 2.0 TreeView, the TreeNode isn't a control so
    it doesn't have a Visible property (as you've discovered). It's just a data
    structure for telling the tree what to render. So, the absence of the TreeNode
    in the TreeView's Node's collection will prevent it from displaying.

    -Brock
    DevelopMentor
    http://staff.develop.com/ballen



    > Hi,
    >
    > How do I hide a TreeNode programmatically? the IsVisible property of a
    > node is readonly. Any suggestions?
    >
    > Thanks in Advance,
    > Shafia
    Brock Allen, May 30, 2005
    #2
    1. Advertising

  3. The IsVisible() property returns true when the parent node is expanded,
    otherwise is returns false. There is no property to hide or display a node.

    Gabriel Lozano-Morán

    "Shafia" <> wrote in message
    news:...
    > Hi,
    >
    > How do I hide a TreeNode programmatically? the IsVisible property of a
    > node
    > is readonly. Any suggestions?
    >
    > Thanks in Advance,
    > Shafia
    >
    >
    Gabriel Lozano-Morán, May 30, 2005
    #3
  4. Shafia

    clintonG Guest

    I've got question about this myself and assume we may be able to use the
    XmlDocument class to preprocess the XML file before populating the tree
    control.


    <%= Clinton Gallagher
    METROmilwaukee (sm) "A Regional Information Service"
    NET csgallagher AT metromilwaukee.com
    URL http://metromilwaukee.com/
    URL http://clintongallagher.metromilwaukee.com/




    "Brock Allen" <> wrote in message
    news:...
    > If you're talking about the 2.0 TreeView, the TreeNode isn't a control so
    > it doesn't have a Visible property (as you've discovered). It's just a
    > data structure for telling the tree what to render. So, the absence of the
    > TreeNode in the TreeView's Node's collection will prevent it from
    > displaying.
    > -Brock
    > DevelopMentor
    > http://staff.develop.com/ballen
    >
    >
    >
    >> Hi,
    >>
    >> How do I hide a TreeNode programmatically? the IsVisible property of a
    >> node is readonly. Any suggestions?
    >>
    >> Thanks in Advance,
    >> Shafia

    >
    >
    >
    clintonG, May 30, 2005
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    1,404
  2. Tjerk Wolterink
    Replies:
    2
    Views:
    1,402
    Dimitre Novatchev
    Aug 24, 2006
  3. Shafia

    Hiding a TreeView node

    Shafia, May 30, 2005, in forum: ASP .Net Building Controls
    Replies:
    0
    Views:
    111
    Shafia
    May 30, 2005
  4. Shafia

    Hiding a treeview node

    Shafia, May 30, 2005, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    114
    Shafia
    May 30, 2005
  5. Keith Patrick

    Hiding a TreeView's root node

    Keith Patrick, Nov 11, 2005, in forum: ASP .Net Web Controls
    Replies:
    2
    Views:
    462
    Keith Patrick
    Nov 16, 2005
Loading...

Share This Page