Quantcast
Channel: Active questions tagged excel - Stack Overflow
Viewing all articles
Browse latest Browse all 88054

Updating the Ribbon

$
0
0

My fluent code starts:

<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui" onLoad="RibbonLoader">

And I have a checkbox called "csmFLC"

There is a global variable declared in a standard module:

Public g_RibbonUI As IRibbonUI

And the following routine:

Public Sub RibbonLoader(Thisribbon As IRibbonUI)
    Set g_RibbonUI = Thisribbon
End Sub

However any code using g_RibbonUI such as:

g_RibbonUI.InvalidateControl "csmFLC"

or

g_RibbonUI.Invalidate

results in a error message

Error 91: Object variable or With block variable not set.

It looks to me that g_RibbonUI should have been set and it is definitely the case that the RibbonLoader subroutine IS called. So any ideas as to what is going wrong?


Viewing all articles
Browse latest Browse all 88054

Trending Articles