This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes JTee Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JTee" Watch "JTee" New topic
Author

JTee

NIKHIL EROS
Greenhorn

Joined: Sep 21, 2001
Posts: 17
i have used my own TreeModel by extending TreeModel class, its reprsenting the tree nodes well, i have given my own functionality for deletion as its my TreeModel, but when i delete any node its not getting deleted the same moment.
Instead when i collapse and again expand the Parent Node (from which i deleted the Child Node) then it shows that the Child node has been deleted. I have also tried using Validate() and Paint() funtions as well, but of no use.
please help me soon. Thanks in advance
Matt Hansen
Ranch Hand

Joined: Jul 31, 2001
Posts: 34
You should take a look at this example from Sun: http://java.sun.com/docs/books/tutorial/uiswing/components/tree.html#dynamic
There is code for removing a node from a tree. It can be found on that page or here: DynamicTree.java
 
Consider Paul's rocket mass heater.
 
subject: JTee
 
Similar Threads
displaying child nodes on demand
JTree Scalablity ???
JTree / DataModel Confusion
Parsing a TreeModel structure
showing a text file from a jtree selection path