Is it possible to have more than one custom tab for office tape?

I cannot find documentation to verify this or any working examples.

I want to get something like this xml below, but I think this is really impossible.

<customUI onLoad="Ribbon_Load" xmlns="http://schemas.microsoft.com/office/2010/01/customui"> <ribbon> <tabs> <tab idMso="TabAddIns" label="Ribbon1"> </tab> <tab idMso="TabAddIns" label="Ribbon2"> </tab> </tabs> </ribbon> </customUI> 
+7
c # outlook vsto ribbon outlook-addin
source share
3 answers

You can have multiple tabs if you use output tabs, then set idMso="exiting tabids"

Existing table identifiers must be valid identifiers, which can be found here.

If you use your own tabs, use id="customtab1" instead of idMso

customtab1 - can be any valid string

EDITED

Work with xml tape

 <?xml version="1.0" encoding="UTF-8"?> <customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui" onLoad="Ribbon_Load"> <ribbon> <tabs> <tab idMso="TabAddIns" label="Ribbon1"> <group id="MyGroup" label="My Group"> </group> </tab> <tab id="CustomAddin" label="Ribbon2"> <group id="CustomAddinGroup" label="My Group"> </group> </tab> </tabs> </ribbon> </customUI> 

Try using the Ribbon constructor and convert it to XML and make sure you add the code below to the ThisAddin.cs file

 protected override Microsoft.Office.Core.IRibbonExtensibility CreateRibbonExtensibilityObject() { return new Ribbon1(); } 
+9
source share

Change idMso to id and give the tabs your own name.

 <customUI onLoad="Ribbon_Load" xmlns="http://schemas.microsoft.com/office/2010/01/customui"> <ribbon> <tabs> <tab id="Tab1" label="Ribbon1"> </tab> <tab id="Tab2" label="Ribbon2"> </tab> </tabs> </ribbon> </customUI> 

idMso used to reference Microsoft objects that already exist in the application that hosts the feed.

+2
source share

You cannot have two tabs with the same identifier (idMso = "TabAddIns"). Make sure the identifiers are unique.

+1
source share

All Articles