SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a following requirement in SharePoint 2010.

We need to disable the "Delete Selection" menu option from the recycle bin for SharePoint members. Is there any way to achieve this?

share|improve this question

Although it is certainly possible modifying the internal /_layouts/RecycleBin.aspx page, I personally stay far away from this approach for several reasons (supportability and maintenance to name only two).

Instead I'd recommend the approach outlined here with a DelegateControl.

The simplest way is then to make a copy of the original page, change the copy to fit your needs and use a redirect with the DelegateControl like this:

protected override void OnLoad(EventArgs e)
    if (Context.Request.Url.PathAndQuery.IndexOf("_layouts/settings.aspx", StringComparison.InvariantCultureIgnoreCase) > 0)
        Context.Response.Redirect("MySiteSettingsPage.aspx", true);

A far more complicated approach would be to use the DelegateControl to directly manipulate the wssuc:ToolBarButton control via ASP.NET. Unfortunately I don't have a working example of this approach for you, sorry!

share|improve this answer

There are multiple ways to do this.

I couldn't find a sharepoint specific setting for this. Maybe there is one somewhere..

Anyways, Personally, I'd just edit the /_layouts/RecycleBin.aspx page and remove the button.

Create a copy of the page though before editing it.

Find the following control and add the Visible="false" Attribute :

<wssuc:ToolBarButton runat="server"
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.