Reputation: 11
Good day,
I am trying to add a custom action button for the "edit properties" form ribbon, but the button is still not being displayed. The solution is going to be deployed in a farm level and for a custom list (with id 10001 for this example)
<CustomAction Id="DocumentExchange"
Location="CommandUI.Ribbon.EditForm"
Title="element title"
RegistrationType="List"
RegistrationId="10001">
<CommandUIExtension>
<CommandUIDefinitions>
<CommandUIDefinition Location="Ribbon.DocLibListForm.Edit.Actions.Controls._children">
<Button
Id="ExchangeDocumentButton"
Sequence="1"
Command="ExchangeDocument"
LabelText="label text"
Image32by32="/_layouts/images/myIcon.png"
TemplateAlias="o2"
/>
</CommandUIDefinition>
</CommandUIDefinitions>
<CommandUIHandlers>
<CommandUIHandler
Command="ExchangeDocument"
CommandAction="javascript:alert('Not implemmented functionality call');"
/>
</CommandUIHandlers>
</CommandUIExtension>
I wonder if the problem has to be that is not a sandbox level deployment solution or if some additional solution configuration is missing in the site.
Thank you very much in advance for your help.
Upvotes: 1
Views: 2616
Reputation: 586
I recreated your example and the button shows up on the edit form on a custom document library with a RegistrationId of 10001. So nothing seems wrong.
The custom document library and the custom action are in one project and in one feature in my test environment and I scoped the feature to Site. How did you organize this?
One thing: you are missing the closing tag of CustomAction in the xml. Is this present in your solution?
Is there maybe other code present in your solution which can cause an exception or something?
Regards, Anita
Upvotes: 1
Reputation: 586
Document libraries have RegistrationId of 101, can you try this?
Hope this helps, Anita
Upvotes: 0