Link to home
Start Free TrialLog in
Avatar of tom_corc
tom_corc

asked on

How to do a quick file copy

I have a file c:\directory1\file1.mdb
that I want to copy to c:\directory2 and overwrite file1.mdb in directory2 if it exists in there.
How is this done in java?
Avatar of bobbit31
bobbit31
Flag of United States of America image

Avatar of Mick Barry
Write a batch file and execute it from your Java app :-)
Java does not have a specific method for copying a file, the only way to do is to read the existing file, and write the new one.
ASKER CERTIFIED SOLUTION
Avatar of Venci75
Venci75

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial