我正在尝试使用 Office Ribbon X Editor 在 PowerPoint 的功能区中定义一个动态组合框。当我输入 onAction 行时,出现错误:
Ln 14, Col 25: 'onAction' 属性未声明。
代码:
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<ribbon startFromScratch="false">
<tabs>
<tab id="customTab" label="Custom Tab">
<group id="customGroup" label="Custom Group">
<button id="customButton" label="Custom Button" imageMso="HappyFace" size="large" onAction="Callback" />
<comboBox
id="comboBox"
label="Size"
sizeString="AAAA"
getItemCount="GetCBItemCount"
getItemID="GetCBItemID"
onAction="ddClicked"
>
</comboBox>
</group>
</tab>
</tabs>
</ribbon>
</customUI>
感谢任何帮助
组合框上没有
onAction
。试试onChange
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<ribbon startFromScratch="false">
<tabs>
<tab id="customTab" label="Custom Tab">
<group id="customGroup" label="Custom Group">
<button id="customButton" label="Custom Button" imageMso="HappyFace" size="large" onAction="Callback" />
<comboBox
id="comboBox"
label="Size"
sizeString="AAAA"
getItemCount="GetCBItemCount"
getItemID="GetCBItemID"
onChange="ddClicked"
>
</comboBox>
</group>
</tab>
</tabs>
</ribbon>
</customUI>