C# Overwrite file failed badly -
tried several times make work several failures. let me explain i've tried do:
1.unrar files in zip format (working)
2.unraring named directory (unrars)
3.copying unrars folder folder(not working)
question : did used correct overwrite format? set bool overwrite true.
foreach (string fisier in directory.getfiles(sourcepath, "*.*", searchoption.alldirectories)) { system.io.file.copy(fisier, fisier.replace(thesourcepath, thedestinationpath), true); }
seems odd way destination path me, can't have string?
it might string replace isn't creating valid path.
i assume `thedestinationpath' const, in case won't have file name on it, or you'll copying on file second iteration.
Comments
Post a Comment