2008-12-11 72 views

回答

0

2007年,您可以擴展功能區,並且應該能夠將控件放在Office菜單選項卡中的​​3210組中。我不認爲這是在Visual Studio的最後一個VSTO插件中提供的設計器中支持的,因此您可能必須手工製作您的xml。

<customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui" onLoad="OnLoad" loadImage="OnGetImage"> 
    <ribbon> 
    <officeMenu> 
     <menu idMso="FileSendMenu"> 
     <button id="oButtonId" 
       insertAfterMso="FileInternetFax" 
       getDescription="GetDescription" 
       getLabel="GetLabel" 
       getScreentip="GetSuperTip" 
       getSupertip="GetSuperTip" 
       getVisible="GetVisible" 
       onAction="OnButtonPress"/> 
     </menu> 
    </officeMenu> 
    </ribbon> 
</customUI> 

您將需要一個事件處理程序(「OnButtonPress」),以及有說明處理程序,ICONST等,您可以用VBA做到這一點,但我寧願有一個適當的外接去。

相關問題