Add ADXRibbonButtons to ADXRibbonGroup...

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

Add ADXRibbonButtons to ADXRibbonGroup...
 
Heinz-Josef Bomanns




Posts: 206
Joined: 2008-02-28
Hi,

latest versions of anything ,-) Word 2010/2007 - I try to dynamically add some ADXRibbonButtons to an existing ADXRibbonGroup in AddInStartupComplete like this but it doesn't work, the buttons are not displayed in the group:

    For I = 1 To 10
      Dim btn As New ADXRibbonButton(Me.components) 'also tried without 'Me.components', no success
      With btn
        .Id = "rbtnTest_" & CStr(I)
        .Caption = "Test #" & CStr(I)
        .Size = ADXRibbonXControlSize.Large
        .ImageList = ilIcons_32
        .Image = 0
      End With 'btn
      rboxTest.Controls.Add(btn, ADXRibbons.msrWordDocument)
    Next I

There's no error raised or exception fired. Any hints why this doesn't work? Thanks...
__________________
Greetings, HJB
Posted 26 Jun, 2012 02:06:06 Top
Andrei Smolin


Add-in Express team


Posts: 16994
Joined: 2006-05-11
HJB,

You need to run this code fragment in the OnRibbonBeforeCreate event of the add-in module.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 26 Jun, 2012 02:16:02 Top
Heinz-Josef Bomanns




Posts: 206
Joined: 2008-02-28
Hi Andrei,

i've tried ALL AddIn* event procs but not that one - must have happend due to early morning fog ,-) Thanks...
__________________
Greetings, HJB
Posted 26 Jun, 2012 04:34:30 Top
Andrei Smolin


Add-in Express team


Posts: 16994
Joined: 2006-05-11
You are welcome!

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 27 Jun, 2012 01:46:24 Top