Deleting folders using File Explorer RRS feed

  • Question

  • Hi guys,

    i have document library with more content types and I need to forbid users to delete items with some content types from library (these content types inherit from folder), users still can delete documents. I can do this using ItemDeleting reciever (i check for content type and then I can forbid deleting), but I have problem when users trying to delete these folders using File Explorer. File Explorer deletes underlying object first and then delete folder, so reciever fires for files in folder first, check for content type and files are deleted, folder remains undeleted but its empty.

    I dont want to achieve my functionality using permissions due to performance issues, because I would have to broke role inheritence for each document in folder and I have a lot of documents in library.

    Is there any other way how I can forbid deleting items with specified content type? Thanks a lot

    Thursday, October 17, 2013 8:23 AM


  • Hi Jonas,

    Thanks for your info. Actually we can't forbid deleting items by content type in Windows Explorer because it use different method to display the files.

    Is disabling "Open with Explorer" a workaround? For information about how to disable Open With Explorer button, please refer to


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

    Wednesday, October 23, 2013 3:00 PM

All replies