Question

Please can someone help my sanity :)

I've followed many a blogs including this one : http://msdn.microsoft.com/en-us/library/office/gg549101.aspx#pj14_ModifyPWARibbon_TimesheetRibbon

It removes various buttons etc and is done via activating a feature. All is well in that the buttons are removed but I have behaviour which doesn't reflect the final screenshot they show. I've now tried this on two nevironments too. Whilst my buttons are removed i.e. the remove task button I can only assume some JavaScript error is being thrown (SharePoint swallows errors) as the whole ribbon fails to work. i.e. the drop downs now fail to show any content.

I've gone through and added some buttons back (commented code out) and eventually I can have the ribbon work with a select few of the changes BUT certain buttons break functionality! Is this because there is code trying to enable/disable buttons based on selected like the remove task and with it gone it errors.

Can someone please help my sanity and check this / feedback their experience and even better tell me what the hell I am doing wrong :)

Was it helpful?

Solution 2

After thinking something was wrong with the Server, XML, feature, browser it turns out that the problem is a result of a caching issue!

Basically, one instance of the feature was deployed and activated called "RibbonChanges", later I revisited the solution and renamed the feature based on our standards so I renamed to "Company.RibbonChanges". In having the original feature deactivated and the original solution uninstalled and the new one installed and activated I thought all would be fine. Files on disk where as expected etc! It turns out however there is some caching issue on what I can only presume is the JS being outputted. A simple clear browser history/cache has fixed the issue!!

I also went through the process again, and the issue/outcome was the same.

EDIT: Any modification to XML in general seems to require a cache clear

OTHER TIPS

The error in the example code is:

<!-- Remove the Planned check box for planned work in the Show/Hide group. -->
<
      Id="Ribbon.ContextualTabs.TiedMode.Home.ShowHide.PlannedWork"
      Location="CommandUI.Ribbon"
      Title="Hides the Planned check box in the Timesheet ribbon">
  <CommandUIExtension>
    <CommandUIDefinitions>
      <CommandUIDefinition Location="Ribbon.ContextualTabs.TiedMode.Home.ShowHide.PlannedWork"/>
    </CommandUIDefinitions>
  </CommandUIExtension>
</CustomAction>

Should be:

<!-- Remove the Planned check box for planned work in the Show/Hide group. -->
<CustomAction
      Id="Ribbon.ContextualTabs.TiedMode.Home.ShowHide.PlannedWork"
      Location="CommandUI.Ribbon"
      Title="Hides the Planned check box in the Timesheet ribbon">
  <CommandUIExtension>
    <CommandUIDefinitions>
      <CommandUIDefinition Location="Ribbon.ContextualTabs.TiedMode.Home.ShowHide.PlannedWork"/>
    </CommandUIDefinitions>
  </CommandUIExtension>
</CustomAction>

Try that out.

Licensed under: CC-BY-SA with attribution
Not affiliated with sharepoint.stackexchange
scroll top