I'm trying to add a custom button to a SP2010 ribbon in the DisplayFormToolbar
for a list item. The list is external, although I don't think that matters but still...
This is my custom action definition:
<CustomAction Id="{0116B081-B13E-4A4B-8F8D-EF7AC1E43BFD}"
Location="DisplayFormToolbar"
RegistrationType="List"
RegistrationId="600"
Sequence="1"
ControlAssembly="myAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=...."
ControlClass="myNamespace.MyRibbonButton" />
myNamespace.MyRibbonButton
class extends System.Web.UI.WebControls.Button
and has some basic code inside OnInit
.
When I access the display form of an item in the external list, in debug I can see that OnInit
is executed, there is no exception in the logs... but the button does not show in the form!
I have specified my assembly with SafeControl
so that's not the cause.
Even if I add this to my custom action is still does not display:
<CommandUIExtension>
<CommandUIDefinitions>
<CommandUIDefinition Location="Ribbon.ListForm.Display.Manage.Controls._children" />
</CommandUIDefinitions>
</CommandUIExtension>
What could I be missing?