Win a copy of OCP Java SE 8 Programmer II Exam Study Guide this week in the OCP forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

transfer files from one folder to another in java  RSS feed

 
Ranch Hand
Posts: 106
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi, my problem is that i know how to access a file within one folder but don't know how to transfer (copy) that same file into another folder. How do i do that in my java code. thanks very much.

p.s., can i use Runtime.exec as in \cmd\copy? or does java have its own method to do that? thanks....
 
Ranch Hand
Posts: 134
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess this should solve your query:



Rgds,
Mehul.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!