problem on treeview

1 view
Skip to first unread message

viji

unread,
Nov 4, 2005, 5:53:29 AM11/4/05
to dotnetindia
Hi friends,

I am facing problem in treeview.My tree structure
keeps changing every time
the page is loaded.I dynamically construct the XML and
bind to it.
The first time it runs fine.The next time when I
select a node and it gets
posted back.the tree gets rebounded and it gets loaded
but I get this error
"subtree.all is null or not an object" line 211 in
.htc file.There is nothing
wrong with i/p as I output it to a file and see that
its perfect XML.

for expandable i gave like this:
top = new TreeNode();
top.Expanded = true;

Please help.

Regards,
viji.




__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com

ST Sreetharan

unread,
Nov 4, 2005, 8:50:41 AM11/4/05
to Techdot...@googlegroups.com
Hi
   Why not you bind the data within IsPostback. I think this will help you
 
if(!isPostBack)
{
//write your logic to bind the tree
}
 
hope this will work fine
Regards
Sreetharan S.T

viji

unread,
Nov 7, 2005, 11:20:43 PM11/7/05
to Techdot...@googlegroups.com
hi sir,
i put my code in !ispostback only..
when i select particular child node twice im getting
javascript error..i cant find w error.


if i give treenodeobj.expanded = true.then always it
displays in expanded structure only.

but i dont want like this.for that w to do.

if i ll give false then only this javascript error is
coming.
"subtree.all is null or not an object" line 211 in
.htc file.

__________________________________
Yahoo! FareChase: Search multiple travel sites in one click.
http://farechase.yahoo.com
Reply all
Reply to author
Forward
0 new messages