Hi everyone! Need your help on creating dynamic RibbonXML where statement will depend on user that is accessing access database. I created DynamicXML no problem and it changes context depending on user but my main problem is refreshing ribbon. I see that UsysRibbons tables changes fine but it's not being loaded. I have to restart access in order to this to take effect. I tried gobjRibbon.Invalidate method but it doesn't refresh ribbon for some reason... Here is my code:
I created new module with name "Ribbon" and put this in there:
Option Compare Database
Option Explicit
Public gobjRibbon As IRibbonUI
Public Sub CallbackOnLoad(Ribbon As IRibbonUI)
' Callbackname in XML File "onLoad"
Set gobjRibbon = Ribbon
End Sub
and then in form that validates a user I put:
If (Not gobjRibbon Is Nothing) Then
gobjRibbon.Invalidate
End If
No success... What am I doing wrong?
I created new module with name "Ribbon" and put this in there:
Option Compare Database
Option Explicit
Public gobjRibbon As IRibbonUI
Public Sub CallbackOnLoad(Ribbon As IRibbonUI)
' Callbackname in XML File "onLoad"
Set gobjRibbon = Ribbon
End Sub
and then in form that validates a user I put:
If (Not gobjRibbon Is Nothing) Then
gobjRibbon.Invalidate
End If
No success... What am I doing wrong?
Last edited: