将Excel UIribbon行为中的按钮切换为单选按钮

时间:2016-04-14 15:11:06

标签: xml excel excel-vba uiribbon vba

我想切换excel UIRibbon中的按钮,使其表现得像单选按钮,也就是说,如果我按下一个按钮,所有其他按钮都没有按下......这可能吗?

我的xml代码是:

<box id="box1" boxStyle="vertical"> 
                    <toggleButton id="phase1" label="P1" size="large" getPressed="GetPressed" imageMso="Filter"/>
                    <toggleButton id="phase2" label="P2" size="large" getPressed="GetPressed" imageMso="DesignMode"/>
                    <toggleButton id="phase3" label="P3" size="large" getPressed="GetPressed" imageMso="MeetingsWorkspace"/>
                    <toggleButton id="phase4" label="P4" size="large" getPressed="GetPressed" imageMso="ControlsGallery"/>
                    <toggleButton id="phase5" label="P5" size="large" getPressed="GetPressed" imageMso="SignatureShow"/>
                    <toggleButton id="phase6" label="P6" size="large" getPressed="GetPressed" imageMso="RecoverInviteToMeeting"/>
                </box>  

获取每个按钮的状态并更改其余按钮的状态所需的宏是什么?

谢谢!

0 个答案:

没有答案