Resolved Image for a Group In Outlook VSTO

Peque

Member
Joined
Sep 14, 2023
Messages
15
Programming Experience
Beginner
Hi Forum
Have created my own VSTO for outlook,. Which is 2 groups (Where one group is 14Buttons)
So not sure if I'm doing this the right way ?
The Group with the buttons are sometimes folded as a single Button - With a standard symbol from Outlook Symbols.
I cannot find a solutions where I can add the Image to the Group - so that it'll be that little image instead of the defaults
Skærmbillede 2023-09-20 074536.png

I have tried but not finding anything that describe that little point - So is it possible at all to change that Symbols
In the properties I cannot find a options (Or I'm lookingt the wrong place)

So I dont want an image on the buttons itself(14) - But as I can see the only place where to put a image to a group


TIA

Greeting P
 
RibbonGroup interface doesn't support it, so no designer/code support. It is only possible if you define the ribbon in xml.
 
OK
Can you describe a little more - Since I have been looking that way - but without any luck
my 2 images(png files) are located under resouces - (Since they are used in resource for a DropDown Menu in One of the Groups)

Since I found this link from 2007 - But can not make it work - for the group.
Allso tried this Solution without any luck

In Ribbon.xml
Ribbon1.xml:
<customUI onLoad="Ribbon_Load" xmlns="http://schemas.microsoft.com/office/2009/07/customui" loadImage="GetImage">
// The Group
<tab idMso="TabMail">
 <group id="group4" label="Glasshop A/S Shops" image="GS-icon.png">

And from my ribbon.cs
C#:
        public System.Drawing.Image GetImage(string ImageName)
        {
            return (System.Drawing.Image)OutlookAddIn1.Properties.Resources.ResourceManager.GetObject(ImageName);
        }
So not sure if I doing it all wrong here ?
 
If you open the ribbon in designer there is a "Export ribbon to XML" quick action in Properties window.
You get an xml file where you can add the imageMso attribute, for example:
XML:
<group id="Group11" label="Group11" imageMso="RefreshAll">
and you get a ribbon.vb file with some explanations (override CreateRibbonExtensibilityObject and convert event handlers to RibbonX model).
 
Hi John
Thanks for explaning it - But I think that just what i did - in results from google etc. maybe I don't get it at all :)
But I do get confused over the default name is Ribbon1 - and not Ribbon in my head ( it is hard to read / understand al lthe language )


So if I want to use/see the icon that solution, I should move all my code from Ribbon1.cs to the newly genereated Ribbon.cs - is that correctly understanded ?
SInce I have been trying that - to use that (without any other functions for working than the image when the 14 buttons Group when outlook collapse them)
 
Last edited:
I would agree with that, move and comply with the different development model.
 
Back
Top Bottom