Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Regarding Selection of content of jtree node  RSS feed

 
Naveen Kushwaha
Greenhorn
Posts: 4
Chrome Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I created a simplefilebrowser which use jtree to show file system view.
i want to write a code to copy the content of selected node to any other location.
just like copying application do.
help me.
plszz.
 
Darryl Burke
Bartender
Posts: 5167
11
Java Netbeans IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Naveen and welcome to the Ranch! I think you need to explain your requirement and the problem you face in a more specific way. For one, an IDE is an Integrated Development Environment -- not a file browser. JFileChooser already has this functionality, so you should not need to code your own UI to display the file system in a JTree.

If your problem is with reading and writing files, then the question probably belongs in the I/O and Streams section.
http://www.coderanch.com/forums/f-38/Streams

 
Rob Spoor
Sheriff
Posts: 20893
81
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What have you tried already? Do you know how to listen to selection events? Do you know how to get the selected element(s)?
 
Naveen Kushwaha
Greenhorn
Posts: 4
Chrome Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Darryl Burke wrote:Hi Naveen and welcome to the Ranch! I think you need to explain your requirement and the problem you face in a more specific way. For one, an IDE is an Integrated Development Environment -- not a file browser. JFileChooser already has this functionality, so you should not need to code your own UI to display the file system in a JTree.

If your problem is with reading and writing files, then the question probably belongs in the I/O and Streams section.
http://www.coderanch.com/forums/f-38/Streams


sir actually i made a copying application which select node content from jtree(may be from multiple node )and copy or move to a different location in system.
then i am facing problem in writing code snippet for this action.
so just need some hint.
 
Naveen Kushwaha
Greenhorn
Posts: 4
Chrome Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Rob Spoor wrote:What have you tried already? Do you know how to listen to selection events? Do you know how to get the selected element(s)?

i made jtree and wants to copy the content of jtree node to another location when a jbutton is clicked, for selection of final destination i use JFileChooser.
but not able to do so.
not too much know .
if there is better study site plszz provide me.
 
Darryl Burke
Bartender
Posts: 5167
11
Java Netbeans IDE Opera
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Naveen Kushwaha wrote:if there is better study site plszz provide me.


Please UseRealWords.

You could start here:
http://download.oracle.com/javase/tutorial/essential/io/index.html
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!