Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Retrieving String specified Node in JTree  RSS feed

 
Nicolas Viollin
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi !!
I would like to retrieve a String specified node (let say "Hello world") from my JTree, How do I do that ???
thnx
Nico
 
Vinod Chamoli
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
you can get string name of the node clicked. For this you need to implement TreeExpansionListener.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!