DBE
13th December 2005 16:01 UTC
Duration of Copy Proces
Hi,
I'm using a setup script that will copy files from DVD to the Hard Disk.
Do do this, I use the CopyFiles command.
I have the /SILENT parameter on, as I don't want the Windows Copy Proces box popping up!
Is there any way of displaying the approximate time the Copy Process will take?
Afrow UK
13th December 2005 16:10 UTC
You could probably estimate it by getting the file size of the files to copy, but this won't be very good as the time will be different depending on the system.
You can get the size of all files within a folder and its subfolders with the Locate plugin by Instructor:
http://forums.winamp.com/showthread....light=get+size
-Stu
Animaether
13th December 2005 21:14 UTC
A trick I'm using in a different (also limited) language is this...
get the size of the file
start copying it externally (so script won't halt and wait for the copy to be done*)
check the size of the file at the destination location - it should return the size of the file at that time**
base any progress bar / time remaining stuff on that
* you'll need to throw the script into a loop of some sort so that it can perform the check, and continue running once the file is all there
** on some systems you may get a filesize '0' instead. You could try mucking about with free drive space instead (should decrease as the file gets copied), but you cannot rely on its values for accurate display and definitely not for detection of whether the file is all there (other processes may write to / delete (from) files!)
Maybe there's a plugin that already does what you need, though ;)