Hi,
There is no way to know the exact time left, but there are ways to simulate it.
1) Keep track of the starting time and the total number of files to copy.
2) After each copied file, find out the average time of total files copied
3) Using the average time, multiply by number of files left to copy
4) Display the calculate the estimated end time and display it in a Label or similar
5) Call Application.DoEvents() to force a GUI update.
A better estimate would be found with total number of bytes copied and total number of bytes left.
An event better estimate would be to scrap CopyTo and handle your own copying using a Stream. This way lets you update the time in the middle of copying a single file.
Also consider putting the copying part in its own Thread to keep the GUI responsive.
Good Luck!
On Thu, 22 Feb 2007 17:17:16 +0100, <sc**********@t-online.dewrote:
Hi,
i use the CopyTo - Function to copy large files into a net drive. Now
it would be mad, if I could indicate the remaining time or also the
status (in %) to the copying action. Have unfortunately still nothing
found... Is there a possibility?
--
Happy coding!
Morten Wennevik [C# MVP]