File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes how to fill the jtree with the last modified value ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "how to fill the jtree with the last modified value ?" Watch "how to fill the jtree with the last modified value ?" New topic
Author

how to fill the jtree with the last modified value ?

naved momin
Ranch Hand

Joined: Jul 03, 2011
Posts: 682

i need your help guyz i have coded a program with Jtree which is just displaying two nodes and 2 leaf nodes in one node and one is root
and also i have implemented a code within that to change the name of any leaf node dynamically means user can change the name as per his needs
till now it works fine , i mean the code does his job well by allowing to edit the nodes and rename them , but problem occurs when i restart that application the earlier modifications are just lost
and that was very easy to catch it was happening because i was filling the tree with the hard coded values from the constructor ...but i need to know how to replace my modified value with the hard coded ones because at any cost i need to fill the tree at start up so that user can see all its files
but how is this possible to retrieve the last change and replace it when we are filling the tree at start up so that our users can see the modified name of any file ?

code is


The Only way to learn is ...........do!
Visit my blog http://inaved-momin.blogspot.com/
naved momin
Ranch Hand

Joined: Jul 03, 2011
Posts: 682

naved momin wrote:i need your help guyz i have coded a program with Jtree which is just displaying two nodes and 2 leaf nodes in one node and one is root
and also i have implemented a code within that to change the name of any leaf node dynamically means user can change the name as per his needs
till now it works fine , i mean the code does his job well by allowing to edit the nodes and rename them , but problem occurs when i restart that application the earlier modifications are just lost
and that was very easy to catch it was happening because i was filling the tree with the hard coded values from the constructor ...but i need to know how to replace my modified value with the hard coded ones because at any cost i need to fill the tree at start up so that user can see all its files
but how is this possible to retrieve the last change and replace it when we are filling the tree at start up so that our users can see the modified name of any file ?

code is

done solved
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to fill the jtree with the last modified value ?
 
Similar Threads
JPopup and JTree Problem
Jtree - message becomes blurry when scrolls
JTree
need help with jTree isNodeAncestor()
Gett8ing focus when 2 JTrees in same panel.