Quantcast
Channel: Developing Apps for SharePoint 2013 forum
Viewing all articles
Browse latest Browse all 8089

Ribbon Customization on Document Set Manage tab not working

$
0
0

Hello,

I am developing a SharePoint 2013 site that is a migration of a 2010 site. By that I mean I'm rewriting everything from scratch to use SharePoint Apps in 2013. 

I have an app that shows custom ribbon buttons on the Document Set Home Page. The buttons appear as they should and work fine UNTIL I modify the Document Set Home Page. The modification involves removing the "Document Set Contents" web part and replacing it with a "List View" web part (There are reasons for this which are not germane to this discussion). 

Anyway, once the web parts are changed, the custom ribbon buttons appear on the Manage tab, but they are always grayed out, so they can never be clicked. 

Below is the "Elements.xml" showing the customization. Any help would be appreciated. 

By the way, this worked fine in SharePoint 2010. The document set home page was set up in the same manner. Undoubtedly the new App model has changed something, but I can't figure out what. 

Thanks

Doug H.

--------------------------------------------------------------------------

Elements.xml:

<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
    <CustomAction Id="TheSite.SharePoint.Ribbon.CustomTab"
                  Sequence="100"
                  RegistrationType="List"
                  RegistrationId="{$ListId:Base%20Files;}"
                  Location="CommandUI.Ribbon">
  
        <CommandUIDefinition Location="Ribbon.ManageDocumentSet.MDS.Manage.Controls._children">
          <Button Id="Ribbon.Documents.Manage.RibbonCustomizationsButton.Subscribe"
                          Sequence="100"
                          Command="MySite.Command.Subscribe"
                          LabelText="Subscribe"
                          TemplateAlias="o1"
                          ToolTipTitle="Subscribe to this document set"
                          ToolTipDescription="Add this document set to your home page"
                          Image32by32="_layouts/15/images/ctoa32.png"
                          Image16by16="_layouts/15/images/ctoa16.png" />
        </CommandUIDefinition>
        <CommandUIDefinition Location="Ribbon.ManageDocumentSet.MDS.Manage.Controls._children">
          <Button Id="Ribbon.Documents.Manage.RibbonCustomizationsButton.Unsubscribe"
                  Alt="Unsubscribe"
                  Sequence="100"
                  Command="MySite.Command.Unsubscribe"
                  LabelText="Unsubscribe"
                  TemplateAlias="o1"
                  ToolTipTitle="Unsubscribe to this document set"
                  ToolTipDescription="Remove this document set from your home page"
                  Image32by32="_layouts/15/images/ctor32.png"
                  Image16by16="_layouts/15/images/ctor16.png" />-->
        </CommandUIDefinition>
        </CommandUIDefinitions>
      <CommandUIHandlers>

        <CommandUIHandler 
          Command="MySite.Command.Subscribe"
          EnabledScript="true"
          CommandAction="~appWebUrl/Pages/SubscribeDialog.aspx?Source={Source}&amp;{StandardTokens}" />
        <CommandUIHandler 
          Command="MySite.Command.Unsubscribe"
          EnabledScript="true"
          CommandAction="~appWebUrl/Pages/UnsubscribeDialog.aspx?Source={Source}&amp;{StandardTokens}" />
       
      </CommandUIHandlers>
    </CommandUIExtension >
  </CustomAction>
</Elements>


Doug Haining



Viewing all articles
Browse latest Browse all 8089

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>