I have different Excel add-in's (*.xlam) and they all have the same “tab id” and same labels. However when I load them to the same Excel file, each “add-in” creates a separate ribbon with the same name. Is there any way to group them under the same ribbon when they are loaded separately?
Two of the XML codes for the ribbons are as below:
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<ribbon>
<tabs>
<tab id="CompanyFunctions" label="Company Functions ">
<group id="GrpLogOn" label="Int_Functions">
<button id="CalculateX" label=" Calculate X" imageMso="TableDrawTable" onAction="startCalculateX " size="large" />
</group>
</tab>
</tabs>
</ribbon>
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<ribbon>
<tabs>
<tab id="CompanyFunctions" label="Company Functions ">
<group id="GrpLogOn" label="Int_Functions">
<button id="CalculateY" label=" Calculate Y" imageMso="TableDrawTable" onAction="startCalculateY " size="large" />
</group>
</tab>
</tabs>
</ribbon>
You should use idQ instead of Id to make them share the same tab/group:
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui"
xmlns:myaddins="myuniquekey">
<ribbon>
<tabs>
<tab idQ="myaddins:CompanyFunctions" label="Company Functions ">
<group idQ="myaddins:GrpLogOn" label="Int_Functions">
<button id="CalculateX" label=" Calculate X" imageMso="TableDrawTable" onAction="startCalculateX " size="large" />
</group>
</tab>
</tabs>
</ribbon>
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui"
xmlns:myaddins="myuniquekey">
<ribbon>
<tabs>
<tab idQ="myaddins:CompanyFunctions" label="Company Functions ">
<group idQ="myaddins:GrpLogOn" label="Int_Functions">
<button id="CalculateY" label=" Calculate Y" imageMso="TableDrawTable" onAction="startCalculateY " size="large" />
</group>
</tab>
</tabs>
</ribbon>