I am adding SplitButton to the Media Group in the Interst Tab. However, if i supply Command="InsertImage", then the SplitButton works just fine, if i remove it the SplitButton gets disabled! The problem is that i have a forced item in the menu called "From SharePoint", although i have two buttons only in my SplitButton, but it appears 3.
Here is my code for the SplitButton:
<?xml version="1.0" encoding="utf-8"?>
<Elements xmlns="http://schemas.microsoft.com/sharepoint/">
<CustomAction
Id="COB.SharePoint.Ribbon.NewGroupInExistingTab"
Location="CommandUI.Ribbon">
<CommandUIExtension>
<CommandUIDefinitions>
<CommandUIDefinition Location="Ribbon.EditingTools.CPInsert.Media.Controls._children">
<SplitButton
Id="Ribbon.EditingTools.CPInsert.Video"
Command="InsertImage"
CommandMenuOpen="InsertImageMenuOpen"
CommandMenuClose="InsertImageMenuClose"
Image16by16="/_layouts/images/lg_icwmd.gif"
Image32by32="/_layouts/images/lg_icwmd.gif"
LabelText="Metro Blogs Videos"
MenuAlt="Metro Blogs Videos"
Sequence="20"
TemplateAlias="o1"
ToolTipTitle="Metro Blogs Videos"
ToolTipDescription="Metro Blogs Videos">
<Menu Id="Ribbon.EditingTools.CPInsert.Media.Image.Menu">
<MenuSection
Id="Ribbon.EditingTools.CPInsert.Media.Image.Menu.Video"
DisplayMode="Menu"
Sequence="10">
<Controls Id="Ribbon.EditingTools.CPInsert.Media.Image.Menu.Image.Controls">
<Button
Id="Ribbon.EditingTools.CPInsert.Media.Image.Menu.Image.FromComputer"
Sequence="10"
Command="UploadVideoFromComputer"
LabelText="Insert ImageFrom Computer"
ToolTipTitle="Insert ImageFrom Computer"
ToolTipDescription="Insert ImageFrom Computer"/>
<Button
Id="Ribbon.EditingTools.CPInsert.Media.Image.Menu.Image.FromAddress"
Sequence="20"
Command="UploadVideoFromAddress"
LabelText="Insert Video From Address"
ToolTipTitle="Insert Video From Address"
ToolTipDescription="Insert Video From Address"/>
</Controls>
</MenuSection>
</Menu>
</SplitButton>
</CommandUIDefinition>
</CommandUIDefinitions>
<CommandUIHandlers>
<CommandUIHandler
Command="UploadVideoFromComputer"
CommandAction="javascript:UploadVideoFromComputer();"/>
<CommandUIHandler
Command="UploadVideoFromAddress"
CommandAction="javascript:UploadVideoFromAddress();"/>
</CommandUIHandlers>
</CommandUIExtension>
</CustomAction>
<CustomAction
Id="UploadVideo.Script"
Location="ScriptLink"
ScriptSrc ="/_layouts/1033/MicrosoftServices.Social.MetroBlogs/JavaScripts/RibbonCustomActions.js"/>
</Elements>