This is a migrated thread and some comments may be shown as answers.

RadTreeview Checkboxes="True" broken. Won't return values.

4 Answers 123 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Paul
Top achievements
Rank 1
Paul asked on 16 Mar 2009, 07:53 PM
I submitted a bug report, but thought I'd post this here too in case anyone else is having this problem.

The issue is only with build 2009.1.311.

If you try to iterate through the nodes of your treeview to determine the checked nodes text &/or value, this functionality has broken since the previous builds.

I.E. This code used to work:

string selected = "";  
 
foreach (RadTreeNode node in RadTreeView1.CheckedNodes)  
  {  
     if ((node.Checked == true) && (node.CheckState != TreeNodeCheckState.Indeterminate))  
     {  
        selected += node.Text + ",";  
     }  
  } 

 

RadTreeView1.CheckedNodes would properly return the number of checked nodes. In 2009.1.311 however this always returns 0 therefore it will never run the code to determine what is checked.

The only solution for the moment is to revert back to a previous build.

 

 

 

4 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 17 Mar 2009, 07:51 AM
Hello Paul,

This seems to be working quite well in our online demo. You can check a few nodes in the left treeview and click the "More Info On Selected Nodes" button. What is different in your case?

All the best,
Albert
the Telerik team


Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
0
Paul
Top achievements
Rank 1
answered on 17 Mar 2009, 04:56 PM
Posted to my support ticket, but for everyone elses benefit:

The main difference is mine happened to exist within a master page. If I tested my control outside of this setup then it worked as expected.

I've commented out practically everything in my masterpage and I've narrowed it down to the root cause.

The issue exists with the RadFormDecorator control.

If you add one on the page then the problem appears. This appears to have cropped up in the 2009.1.311 build, because it worked perfectly fine with the BETA build. And I know some changes had been made to the RadFormDecorator control. Whatever it was broke this functionality. Disabling this from my masterpage instantly made my controls return values from checkboxes but of course I lost all my decorations.

For now I will continue using the BETA dll until this problem can be patched. Please notify and send me an unofficial build when this gets fixed for me to test out.

Regards,

Paul Groetzner
0
Mike
Top achievements
Rank 1
answered on 25 Mar 2009, 09:23 PM
I get the same thing with the formdecorator and a treeview with checkboxes.  The checkednodes collection does not update from the client after postback.  Removed the decorator  and it works as expected.  Thanks for saving me some time Paul.

Mike
0
Paul
Top achievements
Rank 1
answered on 25 Mar 2009, 09:43 PM
No problem Mike.

It's been classified as a bug and Telerik is working on a fix. For now you can set ControlsToSkip="CheckBoxes" and it will work while not losing the rest of your decorations.

Paul
Tags
TreeView
Asked by
Paul
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Paul
Top achievements
Rank 1
Mike
Top achievements
Rank 1
Share this question
or