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
440
XamTree inside busyindicator
posted

I have a XamTree inside busyindicator. The xamtree with checkbox visibility is true, and it binds to a Hierarchical.

<ig:XamDataTree x:Name="pgaDataTree" NodeCheckedChanged="pgaDataTree_NodeCheckedChanged" >
       <ig:XamDataTree.CheckBoxSettings>
                <ig:CheckBoxSettings CheckBoxVisibility="Visible"

                                                         CheckBoxMode="Manual"

                                                         IsCheckBoxThreeState="False" />
                 </ig:XamDataTree.CheckBoxSettings>
                          <ig:XamDataTree.GlobalNodeLayouts>
                                             <ig:NodeLayout  Key="ProblemLayout"

                                                                           TargetTypeName="Problem" 

                                                                           DisplayMemberPath="Description">
                                                           <ig:NodeLayout.ExpandedIconTemplate>
                                                                      <DataTemplate>
                                                                              <Image Style="{StaticResource CPProblemImage}" />
                                                                         </DataTemplate>
                                                            </ig:NodeLayout.ExpandedIconTemplate>
                                                            <ig:NodeLayout.CollapsedIconTemplate>
                                                                          <DataTemplate>
                                                                                    <Image Style="{StaticResource CPProblemImage}" />
                                                                           </DataTemplate>
                                                               </ig:NodeLayout.CollapsedIconTemplate>
                                               </ig:NodeLayout>
                                               <ig:NodeLayout Key="GoalLayout"  

                                                                            TargetTypeName="Goal"

                                                                            DisplayMemberPath="Description">
                                                       <ig:NodeLayout.ExpandedIconTemplate>
                                                                 <DataTemplate>
                                                                           <Image Style="{StaticResource CPGoalImage}" />
                                                                   </DataTemplate>
                                                         </ig:NodeLayout.ExpandedIconTemplate>
                                                         <ig:NodeLayout.CollapsedIconTemplate>
                                                                        <DataTemplate>
                                                                                    <Image Style="{StaticResource CPGoalImage}" />
                                                                          </DataTemplate>
                                                           </ig:NodeLayout.CollapsedIconTemplate>
                                                    </ig:NodeLayout>
                                                    <ig:NodeLayout Key="ApproachLayout"

                                                                                  TargetTypeName="Approach"

                                                                                  DisplayMemberPath="Description">
                                                          <ig:NodeLayout.ExpandedIconTemplate>
                                                                      <DataTemplate>
                                                                                    <Image Style="{StaticResource CPApproachImage}" />
                                                                       </DataTemplate>
                                                           </ig:NodeLayout.ExpandedIconTemplate>
                                                            <ig:NodeLayout.CollapsedIconTemplate>
                                                                           <DataTemplate>
                                                                                  <Image Style="{StaticResource CPApproachImage}" />
                                                                            </DataTemplate>
                                                             </ig:NodeLayout.CollapsedIconTemplate>
                                                           </ig:NodeLayout>
                           </ig:XamDataTree.GlobalNodeLayouts>
                  </ig:XamDataTree>

Here all the binding steps

1. Show busyindicator

2. Call RIA service get all item soure

3.Bind  ItemSource to xamtree

4.Hide busyindicator

The first binding is OK. Then if the user user click a button to trigger rebind the xamtree with updated datasoure.  The second binding, all the Nodes are disable (can not expand or select any node) Eventhough i try to enable all the nodes using below function it does not work

 private void EnableTreeNodes(bool enable, XamDataTreeNodesCollection nodes)
    {
            foreach (XamDataTreeNode node in nodes)
            {
                node.IsEnabled = enable;
                if (node.HasChildren) EnableTreeNodes(enable, node.Nodes);
            }

       }

If XamTree is not inside the busyindicator, everything works fine.

Please hep

Parents
No Data
Reply
  • 21382
    posted

    I tried out your issue with the attached sample but could not reproduce your results.  I know however that there was a bug in the release of the DataTree where controls would maintain their disable state.  I am attaching the sample I used,if you are still having a problem with this I would check to see if you are using the latest service release. 

     

Children
No Data