wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes how to expand only selected node in one level  in JTree? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "how to expand only selected node in one level  in JTree?" Watch "how to expand only selected node in one level  in JTree?" New topic
Author

how to expand only selected node in one level in JTree?

sridhar bvap
Greenhorn

Joined: Mar 12, 2008
Posts: 19
Hi to all,
iam using JTree.What i want is, when i select a perticular node in one level, the tree has to display only child nodes of selected node, the other nodes in that level automatically collapse if they already expanded. That is in a one level only one node has to expand, the other nodes has to collapse.
If any budy knows this please help me.

Thanks to one and all.
[ March 31, 2008: Message edited by: sridhar bvap ]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to expand only selected node in one level in JTree?
 
Similar Threads
How to schedule a task higher priority in a worker thread?
Expand/Collapse functionality on JSP page
TreeSelectionEvent, TreeExpansionEvent not fired in swing GUI on JRE 1.6
Child windows not getting closed
Highlight multiple nodes in jtree