File is copying
-
Surely if you call
System.IO.File.Copy
synchronously you'll know when it finishes when the call returns?
Regards, Rob Philpott.
-
Surely if you call
System.IO.File.Copy
synchronously you'll know when it finishes when the call returns?
Regards, Rob Philpott.
-
sorry that isn't what i want because i am not the coppier. the file will be copied by someone else and i will work with the file. but i must get to know if the file was copied completely before i work with it
If you try the following code
try{
System.IO.File.OpenWrite("MyFile.txt");
} catch (System.IO.IOException ex) {
System.Windows.Forms.MessageBox.Show("File is locked");
}This will throw an error because the file is locked if it is still copying.
If you have knowledge, let others light their candles at it. Margaret Fuller (1810 - 1850)
-
If you try the following code
try{
System.IO.File.OpenWrite("MyFile.txt");
} catch (System.IO.IOException ex) {
System.Windows.Forms.MessageBox.Show("File is locked");
}This will throw an error because the file is locked if it is still copying.
If you have knowledge, let others light their candles at it. Margaret Fuller (1810 - 1850)
Simple and to the point 'The Man from U.N.C.L.E.'
Thanks and Regards, Aby
-
If you try the following code
try{
System.IO.File.OpenWrite("MyFile.txt");
} catch (System.IO.IOException ex) {
System.Windows.Forms.MessageBox.Show("File is locked");
}This will throw an error because the file is locked if it is still copying.
If you have knowledge, let others light their candles at it. Margaret Fuller (1810 - 1850)