disabled Checkbox required for some of the treeview items

2 posts, 1 answers
  1. Balaji
    Balaji avatar
    19 posts
    Member since:
    Dec 2010

    Posted 20 Sep 2011 Link to this post

    My Treeview's ItemsOptionListType is set to CheckList and binded it with data. 
    My requirement is:-
    For some of treeviewitem's checkbox need to be Read only.
    I am able to set IsEnable to 'false' in ItemContainerStyle then total item appearance is is disabled mode.
    But i want to set IsReadOnly to True which is not available as i want to see same look for all treeview items.

    Any Suggestions?

  2. Answer
    Petar Mladenov
    Petar Mladenov avatar
    3062 posts

    Posted 23 Sep 2011 Link to this post

    Hi Balaji,

     As I managed to understand you want to have CheckBoxes on all of your RadTreeViewItems and some of them should be disabled (for particular items). Since your RadTreeView is bound , you have to create a Custom Style of the RadTreeViewItem (edit the default one and set IsReadOnly to true on the CheckBox element) and the use StyleSelector to set this custom style only to particular items. You may find these article helpful:
    Styling the RadTreeViewItem
    Please let us know if you need further assistance or info. 

    Petar Mladenov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Back to Top