I am developing an Outlook plugin. I have added a ribbon with the ribbon type set to
this.RibbonType = "Microsoft.Outlook.Explorer";
and ControlId is set to TabMail. By default this ribbon shows on the Home tab in Outlook. But when I open an email in a separate window, when I switch to a different tab or when I view attachments, the ribbon does not appear. I also want to show this ribbon on the Message tab and the Attachments tab.
I have explored ways and got answers that refer to creating two ribbons, but that is not a proper solution.
I also followed this link, but with no luck.
The other solution i explored is to call event tabControl_SelectedIndexChanged on tabs to identify the current tab and then setting ribbon properties(ribbontype and ribbon control) run time.
How to do that for ribbon (Visual Designer)? Or I have to convert that into ribbon (xml)? And where to trigger that event?
Any help will be appreciated.
You should create a new Ribbon with ribbonType Microsoft.Outlook.Mail.Read and your controlId TabReadMessage
You need to choose appropriate values for the RibbonType property:
you can select such
List item
Microsoft.Outlook.Mail.Compose or
Microsoft.Outlook.Mail.Read
Related
My customer wants to add a button (or menu item) to a right click (context) menu in Outlook 2016+. I've found examples that add items to the ribbon menu, but can't find any examples for the context menu.
My customer describes the activity as browsing to any folder in Outlook, select an item and right click, and then select the custom button to perform an action on that selected mail item. I've got the code written to modify the selected item, I just need the context menu piece.
Below is the example of the menu I want to modify.
Example of Context Menu
Thanks in advance,
Ryan
The Fluent UI is used for customizing context menus in Outlook. For customizing context menus in VSTO add-ins you need to use the ribbon XML markup. The Walkthrough: Create a custom tab by using Ribbon XML explains how to get started. And the Customizing Context Menus in Office 2010 describes the ribbon XML you could use for adding your custom entries for the context menus.
The Extending the User Interface in Outlook 2010 article discusses how to customize the explorer and inspector ribbons, the menus and context menus, and Backstage view in the Outlook UI. It walks through a code sample that illustrates how to customize the ribbon, the context menus, and Backstage view, and examines specific issues that apply to the Outlook UI.
I want my tab to be shown on several ribbon types in Outlook 2010:
Microsoft.Outlook.Mail.Compose,
Microsoft.Outlook.Post.Compose,
Microsoft.Outlook.Response.Compose,
Microsoft.Outlook.Sharing.Compose.
Currently it's shown only on Microsoft.Outlook.Mail.Compose though I selected all types above in designer.
What else I should do to apply me tab for all these ribbons?
And I've just noticed that my tab is not appear if I'm creating new rich text message (Email message using -> Rich text). Why?
Take a look at the OfficeRibbon type properties:
I'm programming an application in WPF using the Ribbon menu, part of the requirements for the application is that I need a commands tab, but this tab should be visible at all times and depending on the active document I would enable/disable the appropriate commands.
My question is, does anyone know a way to split the ribbon menu so that the commands tab is always visible on the right side of the menu?
I'm sure there's an easy answer for this, I just haven't found it yet.
Thanks & Regards!
It's not within the functionality of the ribbon. Why not build a grid with 2 columns, and have the ribbon in the left pane and the custom control on the right? Then you can just style the custom control to match the ribbon.
You can get the source code for the ribbon from CodePlex so you would be able to get the exact style.
It might not be what you wanted to hear, but I think it would be ideal.
I've got a minimal VSTO Addin for Outlook 2010 with a ribbon. My only goal is to display a ribbon (created via designer) with no functionality. From what little I can tell from MSDN ribbons should just automatically be displayed by default, perhaps with tweaking ControlIdType/CustomId properties for tabs.
Alas, tweaking these properties does nothing -- Outlook loads and displays no tab. A simple message box displayed in the ribbon loader reveals it never is triggered. Additionally, I haven't seen any information resources (tutorials, walkthroughs, overviews, etc..) that say anything about needing to manually tell Outlook to display tabs.
How do I get the tabs displayed?
Is there a good resource other than MSDN that's good for VSTO newbies?
To get your ribbon displayed, on the base ribbon in your code change the RibbonType property to be Microsoft.Outlook.Explorer.
What fixed it for me (without starting a new project), in the Ribbon1.vb ribbon design, I clicked on the the Ribbon1 name above the ribbons 'File' button, in the properties pane, clicked on tabs (collection), under the heading 'Design' I changed the name (from Tab1) to something else.
Clicked ok, tested by clicking F5 and it worked. Hope this helps someone else.
I would like to be able to add a button into the outlook ribbon, the idea is that when you access your calendar it would show in the "Home" ribbon. How would I go about doing this, ideas or links?
Thanks.
The main trick in adding to an existing ribbon is that you have to create your own (new) ribbon but set the ControlId property (ribbon designer properties) or the idMso (ribbon xml) to TabHome. The ribbongroups on your ribbon will then be added to the existing Home ribbon.
A complete list of all other ribbon names can be found here