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

How do I hide the "Datasheet view" option (under "View Format") in a list's ribbon menu?

share|improve this question

As described in this article : Remove button from the Ribbon in SharePoint 2010, you can, with a feature, remove existing button.

In your case, the feature.xml file should be :

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="">
          Location="Ribbon.List.ViewFormat.Datasheet" />
share|improve this answer
Aha! Changing the 'Library' in the Location to 'List' allows it to work for lists (with the appropriate RegistrationId). Thanks for your help. I'll award the bounty once the 24 hours have passed. – Stuart Pegg Jul 19 '11 at 13:25
edited :) thx for your hawk eyes – Steve B Jul 19 '11 at 13:45
Word of warning to others using this: it seems to only be compatible with 2010. – Stuart Pegg Jul 22 '11 at 10:19

In addition to Steve B's solution, another 2010-only way of doing this is to set the following property to true:


Unfortunately there appears to be no way to do this in 2007.

share|improve this answer

You could use javascript to do this.

var menuItems = document.getElementsByTagName('ie:menuitem');
for (i=0; i<menuItems.length; i++)
  if (menuItems[i].text == 'Edit in Datasheet')

jQuery version:

$("ie\\:menuitem[text='Edit in Datasheet']").each(function() {
    this.hidden = true;
share|improve this answer

Q: Have you tried simply unchecking the "Allow items in this document library to be edited using the datasheet?" to NO

share|improve this answer
I believe that's the front-end counterpart to SPList.DisableGridEditing, and hence also 2010-specific. – Stuart Pegg Oct 4 '12 at 14:47

Just got to List 'Advance settings' and there is an option that allows you to disable Datasheet view. Just say 'NO' to disable datasheet view.

share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.