|
i have developed a custom ribbon for a custom message class: "IPM.Contacts.MyCustomClass"
i note that inside the GetCustomUI() method I can;t seem to trap whether the ID relates to a custom message class or note, as they both come out as "Microsoft.Outlook.Contact". So I am assigning my custom ribbon to both the standard outlook form and mythingie form at this point. Am I doing this bit right???
case "Microsoft.Outlook.Contact":
return Properties.Resources.MyCustomClassRibbon;
so next i am hiding/showing my tabs on my custom ribbon depending upon whether the messageclass is custom or not which i am ascertaining using GetVisible callback methods. but i dont think this is right because i am dictating what is on the ribbon for the standard contact form here, which i should not be doing, in case changes are made to it in the future. so where am i going wrong???
i include my ribbon code below. thanks for any help.
< customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui">
< ribbon startFromScratch="false">
< tabs>
< tab idMso="TabContact" getVisible="Client_IsStandardRibbon" />
< tab idMso="TabInsert" getVisible="Client_IsStandardRibbon" />
< tab idMso="TabOutlookWrite" getVisible="Client_IsStandardRibbon" />
< tab idMso="TabDeveloperTools" getVisible="Client_IsStandardRibbon" />
< tab idMso="TabAddins" getVisible="Client_IsStandardRibbon" />
< tab id="TabClient" label="Client" insertBeforeMso="TabContact" getVisible="Client_IsCustomRibbon">
< group id="Client_GroupActions" label="Actions">
< button idMso="SaveAndClose" />
< button idMso="SaveAndNew" />
< button idMso="Delete" />
</ group>
< group id="Client_GroupShow" label="Show">
< toggleButton id="Client_ShowPageGeneral" label="General" onAction="Client_ShowPageGeneral" />
< toggleButton id="Client_ShowPageUdf" label="User Defined Fields" onAction="Client_ShowPageUdf" />
< toggleButton id="Client_ShowPageMatters" label="Matters" onAction="Client_ShowPageMatters" />
</ group>
< group id="Client_GroupOptions" label="Options">
< button id="Client_ShowFormUdf" label="Manage User Defined Fields" onAction="Client_ShowFormUdf"/>
</ group>
</ tab>
</ tabs>
</ ribbon>
</ customUI> |