Updating Custom Ribbon Actions

Last few days I saw quite a few forum posts about custom ribbon actions that where
created but where not working as expected, or not updated the second time they got
deployed (see this and this post).

Now assuming you have the same issue; there are two things you need to check:

1) Make sure that you deleted your IE (or other browsers) cache after deploying, since
the ribbon caches quite a lot of stuff.

2) When creating a feature that contains the xml / js for your custom ribbon action
you need to make sure that you add a version to your feature tag. This version needs
to be updated every time you roll-out a new version of your ribbon action.

Adding a version to a feature is fairly simple: if you open the desired feature you
will see a 'button' on the bottom left called manifest, if you click that you have
an option edit options around the same place if you click that you can edit the feature
xml by default it will be:

<?xml version="1.0" encoding="utf-8" ?>

<Feature xmlns="http://schemas.microsoft.com/sharepoint/">

</Feature>

So within that <feature> tag you can add a version="1.0.0.0", so it
would look like:

<?xml version="1.0" encoding="utf-8" ?>

<Feature xmlns="http://schemas.microsoft.com/sharepoint/"
version="1.0.0.0">

</Feature>

Next time you changed something and want to rollout again you can use version="1.0.0.1"
or higher to make sure all files get updated.

Leave a Reply