Directoryinfo.Delete The directory is not empty

Sometimes, when you call the Delete(true) method of Directoryinfo class, you will receive an exception saying “The directory is not empty”…. Some people say that there is some kind of curse in the directory. Finally, building the solution in debug layout seemed to be the root cause. The problem solved by building the solution in relase layout.

Leave a Reply