Can I disable a RadTreeViewItem but still have its children enabled?

4 posts, 1 answers
  1. Andrei Rinea
    Andrei Rinea avatar
    10 posts
    Member since:
    Jun 2008

    Posted 08 Jul 2011 Link to this post

    I have a hierarchy of items and when I double click one item I asynchronously open the document represented by that item in a working area. During the (potentially) long open action I disable that item so the user can't double click it again, or rename it or delete it etc.

    However I've seen that its children also get disabled by this and I don't want this.

    Can I just disable one item without having its children disabled?
  2. Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 13 Jul 2011 Link to this post

    Hello Andrei Rinea,

    When disabling a RadTreeViewItem and having in mind that its child RadTreeViewItems are part of its Template, it is expected that they get disabled too. This is by design and you cannot change it out of the box.

    Regards,
    Petar Mladenov
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

  3. UI for WPF is Visual Studio 2017 Ready
  4. Andrei Rinea
    Andrei Rinea avatar
    10 posts
    Member since:
    Jun 2008

    Posted 13 Jul 2011 Link to this post

    I understand very well as this is something any WPF component does. My question should have been 'is there an (easy?) way to disable the node and have its children enabled'?

    Thank you,
    Andrei Rinea.
  5. Answer
    Petar Mladenov
    Admin
    Petar Mladenov avatar
    2891 posts

    Posted 14 Jul 2011 Link to this post

    Hello Andrei Rinea,

    No , there is no easy way to implement this. You can try to play with the style of the item that you want to be disabled and use its PreviewChecked and PreviewSelected events in order to simulate its disabled behavior.


    Greetings,
    Petar Mladenov
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Back to Top