OaklandJim
Well-known Member
- Joined
- Nov 29, 2018
- Messages
- 833
- Office Version
- 365
- Platform
- Windows
Ribbonmasters
The ribbon journey was more arduous than I expected. Want to add worksheet specific ribbon tabs. Used worksheet ribbon definition data range to input the various criteria needed to define tabs, groups and buttons. Wrote code to generate xml file needed. A lot of work here to learn what to do then hack other's code shared code.
I think I'm close... Below is the xml that my code generates based on entries in the worksheet ribbon definition data range. What might be wrong here? Nothing happens when the file is saved. I confirmed that the file is where it should be. That is, I confirmed that the following exists, is being overwritten by my code.
file:///C:/Users/UserName/AppData/Local/Microsoft/Office/Excel.officeUI
The ribbon journey was more arduous than I expected. Want to add worksheet specific ribbon tabs. Used worksheet ribbon definition data range to input the various criteria needed to define tabs, groups and buttons. Wrote code to generate xml file needed. A lot of work here to learn what to do then hack other's code shared code.
I think I'm close... Below is the xml that my code generates based on entries in the worksheet ribbon definition data range. What might be wrong here? Nothing happens when the file is saved. I confirmed that the file is where it should be. That is, I confirmed that the following exists, is being overwritten by my code.
file:///C:/Users/UserName/AppData/Local/Microsoft/Office/Excel.officeUI
XML:
<mso:customUI xmlns:mso='http://schemas.microsoft.com/office/2009/07/customui'>
<mso:ribbon>
<mso:qat/>
<mso:tabs>
<mso:tab id='tab1' label='Test Ribbon' insertBeforeQ='mso:TabFormat'>
<mso:group id='group1' label='Sorting' autoScale='true'>
<mso:button id='G1Button1' label='Sort Symbol' imageMso='FileSave 'onAction='ButtonG1_1'/>
<mso:button id='G1Button2' label='Sort Quantity' imageMso='PivotTableBlankRowsRemove 'onAction='ButtonG1_2'/>
<mso:button id='G1Button3' label='Sort Value' imageMso='ControlLayoutRemove 'onAction='ButtonG1_3'/>
<mso:button id='G1Button4' label='Sort Accounts' imageMso='ImportExcel 'onAction='ButtonG1_4'/>
</mso:group>
<mso:group id='group2' label='Clear Data' autoScale='true'>
<mso:button id='G2Button1' label='One Fund' imageMso='PivotTableBlankRowsRemove 'onAction='ButtonG2_1'/>
<mso:button id='G2Button2' label='All Funds' imageMso='ControlLayoutRemove 'onAction='ButtonG2_2'/>
</mso:group>
<mso:group id='group3' label='Utilities' autoScale='true'>
<mso:button id='makeStickyNote' label='Sticky Note' imageMso='AppointmentColor6 'onAction='ButtonG3_1'/>
<mso:button id='G3Button2' label='Clear Note' imageMso='AppointmentColor7 'onAction='ButtonG3_2'/>
<mso:button id='G3Button3' label='Freeze Panes' imageMso='AppointmentColor8 'onAction='ButtonG3_3'/>
</mso:group>
</mso:tab>
</mso:tabs>
</mso:ribbon>
</mso:customUI>