I am using a treeview control inside an update panel. The checkednodes collection reset almost every time. Can you help?
I'm going to throw an answer out from left field as there's not a lot to work with here. Let's assume you are populating the Treeview on Page_Load or Page_PreRender. On postback, are you always rebinding the original dataset to the Treeview? Only bind if !IsPostBack and you should be all set.
Eh! Its late, but I thought of updating this post now. I was working on the issue. The problem was that I was compelled to use the treeview under AJAX UpdatePanel. So, if I select a list of nodes in the treeview (my treeview is checkbox enabled), at times I find no checkboxes selected in the code-behind. So I did some study in the behaviours, read different posts in different forums and did some code to handle almost majority of the issues.
Anybody interested in the details may look at my post here: http://www.geekays.net/post/Using-TreeView-inside-AJAX-UpdatePanel.aspx