Most likely you are populating your treenodes in Page_Load and you are not
checking whether the page is posting back.
Page_Load fires every time the page loads (even on postbacks).
The solution to this is - in Page_Load check to see if the page has posted
back and if it is posting back then don't populate the treelist (because it's
already been populated)
so (assuming you were using data binding)
Page_Load(....)
{
if (IsPostBack==fa lse)
{
TreeView.DataBi nd();
// or
PopulateTreeVie w();
}
}
in vb.net it would be
if IsPostback=fals e then
....
end if
Hope this helps.
"JJ297" wrote:
When I click on the Root it appears to double all of the nodes. Is
there something in properities to turn this off?
>
Thanks!
>
>
Comment