M
mike
I am trying to move a directory ( and it's contents to a new
directory). I have tried the following:
System.out.println(nonCCResource.getLocation().toString());
tmpDir = new File (nonCCResource.getParent().getLocation().toString(),
nonCCResource.getName()+".tmp");
boolean success = tmpDir.mkdirs();
File dir = new
File(nonCCResource.getParent().getLocation().toString(),
nonCCResource.getName());
boolean success1 = dir.renameTo(tmpDir);
When checking success1 it is false. And the success is true.
Any ideas how I can do this.
cheers,
//mike
directory). I have tried the following:
System.out.println(nonCCResource.getLocation().toString());
tmpDir = new File (nonCCResource.getParent().getLocation().toString(),
nonCCResource.getName()+".tmp");
boolean success = tmpDir.mkdirs();
File dir = new
File(nonCCResource.getParent().getLocation().toString(),
nonCCResource.getName());
boolean success1 = dir.renameTo(tmpDir);
When checking success1 it is false. And the success is true.
Any ideas how I can do this.
cheers,
//mike