| View previous topic :: View next topic |
| Author |
Message |
Achim Guest
|
Posted: Thu May 12, 2005 3:34 pm Post subject: FileCopyDir stops when one file is inaccessible |
|
|
Bug or feature? Anyway, stopping the copy action is not what you want in most use
FileCopyDir should continue with remaining files in case one of the files it tries to copy is not accessible (locked, for example). Of course ErrorLevel should indicate the failure to carry out the complete task.
Regards, Achim |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10480
|
Posted: Thu May 12, 2005 5:12 pm Post subject: |
|
|
That's a good point. However, FileCopyDir is currently implemented using the OS's function SHFileOperation(), which does not appear to have any means of continuing the operation when an error occurs.
The command could be redesigned to use some other method, but that is not likely in the near future. To work around this, you could use a file-pattern loop to copy the files and folders one by one and do custom error counting and reporting. |
|
| Back to top |
|
 |
Achim
Joined: 12 May 2005 Posts: 2
|
Posted: Thu May 12, 2005 6:25 pm Post subject: |
|
|
| Too bad... I guess I'll have to do that. |
|
| Back to top |
|
 |
|