U
UsenetUser
How to: Hide the Ribbon When Access Starts
I have followed these instructions from the Access online help
precisely. Nothing happens - the ribbon appears as usual.
Also tried deleting the ribbon name from the startup options,
restarted Access, and tried the code below, also from Access help.
Curiously it pops up a 32609 error - customization name already
loaded. Any other way to hide the ribbon on startup?
Function LoadRibbons()
Dim i As Integer
Dim db As DAO.Database
Set db = Application.CurrentDb
For i = 0 To (db.TableDefs.Count - 1)
If (InStr(1, db.TableDefs(i).Name, "Ribbons")) Then
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset(db.TableDefs(i).Name)
rs.MoveFirst
While Not rs.EOF
Application.LoadCustomUI rs("RibbonName").Value,
rs("RibbonXml").Value
rs.MoveNext
Wend
rs.Close
Set rs = Nothing
End If
Next i
db.Close
Set db = Nothing
End Function
I have followed these instructions from the Access online help
precisely. Nothing happens - the ribbon appears as usual.
Also tried deleting the ribbon name from the startup options,
restarted Access, and tried the code below, also from Access help.
Curiously it pops up a 32609 error - customization name already
loaded. Any other way to hide the ribbon on startup?
Function LoadRibbons()
Dim i As Integer
Dim db As DAO.Database
Set db = Application.CurrentDb
For i = 0 To (db.TableDefs.Count - 1)
If (InStr(1, db.TableDefs(i).Name, "Ribbons")) Then
Dim rs As DAO.Recordset
Set rs = CurrentDb.OpenRecordset(db.TableDefs(i).Name)
rs.MoveFirst
While Not rs.EOF
Application.LoadCustomUI rs("RibbonName").Value,
rs("RibbonXml").Value
rs.MoveNext
Wend
rs.Close
Set rs = Nothing
End If
Next i
db.Close
Set db = Nothing
End Function