Let me rephrase. My example probably wasn't good. A lot of things can go wrong when deleting a directory. A file has a readonly attribute set, the directory is opened by the windows explorer. I guess all of them can be handled - however I don't want to do it on my own - is there a wrapper that takes care of that with a simple api?
I find the file system operations in System.IO inadequate. For example, in case a file is opened in a text editor the file can't be saved.
I wondered if there is a more powerful implementation of file system for .net?