Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
470
XamDataTree how to set the node's checkbox not checkable?
posted

Hi Support,

I am using xamdatagrid to binding my business objects and leaf nodes of the tree binding to the class like following

public class Action
{
public string Name { get; set; }
public bool IsAssigned { get; set; }
}

and the node setting is like this:

<ig:NodeLayout Key="ActionLayout" TargetTypeName="Action" DisplayMemberPath="Name" CheckBoxMemberPath="IsAssigned">
<ig:NodeLayout.CheckBoxSettings>
<ig:CheckBoxSettingsOverride CheckBoxVisibility="Visible" ></ig:CheckBoxSettingsOverride>
</ig:NodeLayout.CheckBoxSettings>
</ig:NodeLayout>

But the checkbox is checked able, how could I disable it?

thanks,
Eric 

Parents
No Data
Reply
  • 22015
    Verified Answer
    posted

    Hello Eric,

     

    Thank you for your post!

     

    I have been looking into it and have created a small sample application for you.

    In the sample application I have used the code snippets, that you have provided. Then I have created a simple Style with TargetType CheckBox. In this style I am setting the IsEnabled property of the checkbox to false. Then I am assigning this style to the CheckBoxStyle property into the CheckBoxSettings.

     

    Please find the attached sample application and feel free to let me know if you have any further questions on this matter.

    DataTree_CheckBoxDisabled.zip
Children
No Data