Archive for March 17, 2013

Hide SharePoint Ribbon Items

To hide a menu item from the SharePoint ribbon add a custom action to a module in your Visual Studio SharePoint project:

<customaction Id="CustomIdentifier.Ribbon.Documents.New.NewFolder.Hide"
Location="CommandUI.Ribbon" RegistrationType="ContentType" RegistrationId="0x">
      <commanduidefinition Location="Ribbon.Documents.New.NewFolder">

The example above will hide the New Folder ribbon menu item for all document libraries.

Using a RegistrationType of ContentType and RegistrationId of 0x means it will be applied to all items.
Read more

Register Code Behind InfoPath Form for Web Browsing

This post describes how to deploy a web browser compatible InfoPath form, with code-behind, through a SharePoint feature.

Installing and registering an InfoPath form, along with a custom content type is pretty straight forward once you know the required steps.

Start by creating a content type that inherits from the Forms type. The following is a sample content type’s markup.

< ?xml version="1.0" encoding="utf-8"?>
<elements xmlns="">
  <contenttype ID="0x0101010076AEDEA7CA2A44B59ECB3D491618E052"
        Name="Custom Form CT"
    <documenttemplate TargetName="/FormServerTemplates/CustomForm.xsn"></documenttemplate>

Read more


Get every new post delivered to your Inbox

Join other followers: