Hiding the Built-In Ribbon
Most of the time, your RibbonX customizations will augment the Office program's built-in Ribbon interface by adding one or more custom tabs or by adding new groups and controls to existing tabs. Occasionally, however, your VBA application might require that you hide the built-in Ribbon and display only your custom interface. You'll see in the next few sections that you can hide individual tabs (as well as groups and controls within a tab), but you don't have to hide all the program's tabs individually to hide the built-in Ribbon. Instead, in your custom XML markup you modify the <ribbon> element to include the startFromScratch attribute:
<ribbon startFromScratch = "true|false">
If you set this attribute to true, the Office application hides the built-in Ribbon and displays just your custom interface. Here's some bare-bones XML that does that:
<customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui"> <ribbon startFromScratch="true"> </ribbon> </customUI>
In this tutorial:
- Customizing the Office 2007 Ribbon
- Understanding Ribbon Extensibility
- Extending the Ribbon: An Example
- Step 1: Create a Macro-Enabled Office Document or Template
- Step 2: Create a Text File and Add the Custom XML Markup
- Step 3: Copy the Custom XML Markup File to the Document Package
- Step 4: Rename and Open the Document
- Hiding the Built-In Ribbon
- Creating Custom Tabs
- Customizing an Existing Tab
- Creating Custom Groups
- Customizing an Existing Group