We have custom ribbons on many Excel workbooks. Occasionally we experience an error message from Excel saying the '_getEnabled' macro is disabled (see image). This message appears for every ribbon control that uses a macro to control the enabled property.
The xml in the ribbon is (some names are redacted):
<button id="name_btn" size="large" image="imagename" label="somelabel" getEnabled="VBA_####.######_getEnabled" onAction="VBA_####.######_onAction"/>
and the VBA is:
Sub ######_getEnabled(control As IRibbonControl, ByRef returnedVal)
returnedVal = CheckPermissions("SomeName")
End Sub
Has anyone else seen this error? The error messages appear when another workbook is the active workbook but Excel seems to be trying to refresh the ribbon controls for the workbook that contains the code. As mentioned earlier, this happens occasionally and we have not seen any identifiable pattern.