1

I have given scenario:

  1. Create directory on NFS
  2. If that directory exists delete it with all content and then create empty directory

    if (Directory.Exists(destinationPath)) { Directory.Delete(destinationPath, true); } Directory.CreateDirectory(destinationPath);

Quite simple and it works but only if Im not inside that directory. If user is inside that directory (using for example file explorer) then is being kicked off, directory is deleted but next is not created.

Do you have experience with such a situation?

Snorlax
  • 717
  • 1
  • 7
  • 16
  • Can it help? https://stackoverflow.com/q/329355/1094048 . I mean maybe that `hackish` technique to `wait till OS refreshes state of explorer than try again` helps you also to create directory too – pkuderov Jun 08 '17 at 12:05

0 Answers0