The moose likes HTML, CSS and JavaScript and the fly likes Help needed Regardng Tree Structure Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Help needed Regardng Tree Structure" Watch "Help needed Regardng Tree Structure" New topic

Help needed Regardng Tree Structure

Akhil Jain
Ranch Hand

Joined: Oct 14, 2004
Posts: 74
hi freinds please help me out with this thing.

i am trying to write a jsp file in which through javascrpt i am trying to creat Tree structure(similar to what you see in wndows explorer),but with very simple things.not all those fundoo hi-fi images of folder or all.

see i am working in WSAD and have a two Bean file (.java fle basically).one of them is RootBean and other is ChildBean.the thngs goes like this that the RootBean has one of its own leafNode and a instance of a childBean and childBean itself contains three leaf nodes.

hence there can be any number of same RootBeans and ChildBeans .

what i have to do is to create the tree dynamically through javascript such that it can display the root bean on top with "+" sign in front of it and on clicking that sign it should explore itself as the contents of rootbean which is something like

+ RootBean
+ ChildBean
- leafNode1
- leafNode2
- leafNode3
- leafNode0

hope you got the flow.!

and so on as amny number of Root Beans can be opened.(there number is fixed say 10 for example.)

the crux of the question is .how to load bean properties in jsp to dsplay dynamically using javascript.

can somebody help me out in this..........

if you have any answers to it please mail me at

Thanx in advance

-------------------------------<br />you can't move ahead, unless you try for it.
Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
You need to have all of the bean information written to the page so JavaScript can hide or show it. JavaScript can not talk to the bean/server.

I agree. Here's the link:
subject: Help needed Regardng Tree Structure
It's not a secret anymore!