Display name of file being copied to UI using copyDir
Posted on 2011-09-02
I have a C# Win Form app that uses a background worker and copyDir to copy all the contents of one directory to another. When debugging the Output console prints a nice list of the current file being copied. I'd like to display this info to the user so they can see the progress in addition to the progress bar I'm using. Currently in my backgound worker DoWork method I have the following:
copyDir mycopy = new copyDir();
myAnswer = mycopy.CopyAll(dir1, dir2);
MessageBox.Show("Could not find thumb drive", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Error);
Can this be done?