How to add button in outlook home mail tab and same button on home calendar tab?

Add-in Express™ Support Service
That's what is more important than anything else

How to add button in outlook home mail tab and same button on home calendar tab?
 
KristianG




Posts: 38
Joined: 2011-11-03
Hi,

I am stuck in a place, Actually i am trying to show button on outlook mail's (home) tab and same button on calendar's (home) tab.

I am successfully done with showing my button in Outlook home tab with using (idMso : TabMail and Ribbons : OutlookExplorer ). But when i add that same button (copy/pasting ADXRibbonTab in designer) and change the idMso to TabCalendar and Ribbons to OutlookExplorer it shows nothing, and also ribbon button for home tab also get vanished.

Thanks to you if you please do a little help :)
Posted 08 Dec, 2016 04:57:20 Top
KristianG




Posts: 38
Joined: 2011-11-03
Can you help us on this?
Posted 08 Dec, 2016 07:12:33 Top
Andrei Smolin


Add-in Express team


Posts: 14115
Joined: 2006-05-11
Hello Kristian,

KristianG writes:
Actually i am trying to show button on outlook mail's (home) tab and same button on calendar's (home) tab.


To achieve this you need to use two ADXRibbonTab components: 1) Ribbons=OutlookExplorer, IdMso=TabMail, 2)Ribbons=OutlookExplorer, IdMso=TabCalendar.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 08 Dec, 2016 07:30:44 Top
KristianG




Posts: 38
Joined: 2011-11-03
Hi Andrei,

Yes. We have created two tab components and when we do this none of the ribbon buttons are shown. When I remove the property Ribbons=OutlookExplorer from one of the adxRibbonTabs, it is shown on the other. What am I doing wrong?
Posted 08 Dec, 2016 07:42:36 Top
Andrei Smolin


Add-in Express team


Posts: 14115
Joined: 2006-05-11
Hello Kristian,

Please check this code:

        private void InitializeComponent()
        {
            this.components = new System.ComponentModel.Container();
            this.adxRibbonTab1 = new AddinExpress.MSO.ADXRibbonTab(this.components);
            this.adxRibbonGroup1 = new AddinExpress.MSO.ADXRibbonGroup(this.components);
            this.adxRibbonButton1 = new AddinExpress.MSO.ADXRibbonButton(this.components);
            this.adxRibbonTab2 = new AddinExpress.MSO.ADXRibbonTab(this.components);
            this.adxRibbonGroup2 = new AddinExpress.MSO.ADXRibbonGroup(this.components);
            this.adxRibbonButton2 = new AddinExpress.MSO.ADXRibbonButton(this.components);
            // 
            // adxRibbonTab1
            // 
            this.adxRibbonTab1.Caption = "adxRibbonTab1";
            this.adxRibbonTab1.Controls.Add(this.adxRibbonGroup1);
            this.adxRibbonTab1.Id = "adxRibbonTab_a8fa2f89c05c4250a5b61c9599f925c0";
            this.adxRibbonTab1.IdMso = "TabMail";
            this.adxRibbonTab1.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // adxRibbonGroup1
            // 
            this.adxRibbonGroup1.Caption = "adxRibbonGroup1";
            this.adxRibbonGroup1.Controls.Add(this.adxRibbonButton1);
            this.adxRibbonGroup1.Id = "adxRibbonGroup_1946ce7f3da9451fb02a0cae453502f5";
            this.adxRibbonGroup1.ImageTransparentColor = System.Drawing.Color.Transparent;
            this.adxRibbonGroup1.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // adxRibbonButton1
            // 
            this.adxRibbonButton1.Caption = "myButtonOnTabMail";
            this.adxRibbonButton1.Id = "adxRibbonButton_dbb6545311334bedafaf5570cf3025df";
            this.adxRibbonButton1.ImageTransparentColor = System.Drawing.Color.Transparent;
            this.adxRibbonButton1.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // adxRibbonTab2
            // 
            this.adxRibbonTab2.Caption = "adxRibbonTab2";
            this.adxRibbonTab2.Controls.Add(this.adxRibbonGroup2);
            this.adxRibbonTab2.Id = "adxRibbonTab_d302989aba6442969e62f52088dffc38";
            this.adxRibbonTab2.IdMso = "TabCalendar";
            this.adxRibbonTab2.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // adxRibbonGroup2
            // 
            this.adxRibbonGroup2.Caption = "adxRibbonGroup2";
            this.adxRibbonGroup2.Controls.Add(this.adxRibbonButton2);
            this.adxRibbonGroup2.Id = "adxRibbonGroup_3b23af675ac345e2b950a33707cbc5da";
            this.adxRibbonGroup2.ImageTransparentColor = System.Drawing.Color.Transparent;
            this.adxRibbonGroup2.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // adxRibbonButton2
            // 
            this.adxRibbonButton2.Caption = "myButtonOnTabCalendar";
            this.adxRibbonButton2.Id = "adxRibbonButton_a934da62aa5041fa92528b8e5dddb98c";
            this.adxRibbonButton2.ImageTransparentColor = System.Drawing.Color.Transparent;
            this.adxRibbonButton2.Ribbons = AddinExpress.MSO.ADXRibbons.msrOutlookExplorer;
            // 
            // AddinModule
            // 
            this.AddinName = "MyAddin208";
            this.SupportedApps = AddinExpress.MSO.ADXOfficeHostApp.ohaOutlook;

        }
        #endregion

        private AddinExpress.MSO.ADXRibbonTab adxRibbonTab1;
        private AddinExpress.MSO.ADXRibbonGroup adxRibbonGroup1;
        private AddinExpress.MSO.ADXRibbonButton adxRibbonButton1;
        private AddinExpress.MSO.ADXRibbonTab adxRibbonTab2;
        private AddinExpress.MSO.ADXRibbonGroup adxRibbonGroup2;
        private AddinExpress.MSO.ADXRibbonButton adxRibbonButton2;
    }


Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 08 Dec, 2016 08:07:09 Top