• Post Reply Bookmark Topic Watch Topic
  • New Topic

Jtree implementation - based on structure given  RSS feed

 
anees ahamed
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
I am trying to develop a tree in the following structure.


I have all those folder names and file names inside a vector.I can check whether these names are associated with a file or a folder using a method. The folders can or cannot have children.The folder content will be obtained from the database each time a folder is expanded(this time also, i get the names of the contents inside the particular folder in a vector and I do the same procedure to check whether the name is associated with a file or folder) .

How to implement this?
I made a thorough study from http://java.sun.com/docs/books/tutorial/uiswing/components/tree.html#display
and referred and modified the examples given there to suit my requirements, unfortunately nothing seems to work for me properly(according to my requirement above). If needed I will post the stupid codes developed by me.
Please provide some tips, links or basic codes based on which i can develop the rest.
Regards,
Anees
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the 10 replies here didn't help, or do you just want people to duplicate
what's already been posted?

http://forums.sun.com/thread.jspa?threadID=5337544
 
anees ahamed
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I just sought a second opinion. I never thought that forums.sun.com and javaranch were such closely coupled.
Also, can you give an answer for the 9th reply there?
 
Campbell Ritchie
Sheriff
Posts: 53720
127
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We're not "closely coupled," but it is only courteous to tell us you are posting on Sun and to tell the people on Sun you are posting on JavaRanch. Some people, as you will have seen, post on both sites.
 
Michael Dunn
Ranch Hand
Posts: 4632
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
> Also, can you give an answer for the 9th reply there?

I could, and there is a reasonably simple solution to your problem,
as has been hinted at by the person trying to help you on the sun forum,
but I won't.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!