Function DebugMe()
On Error GoTo errorhandler
Dim i As Integer
For i = 1 To CommandBars.Count
CommandBars(i).Enabled = True
Next i
'reset all toolbars
DoCmd.SelectObject acTable, , True
'unhide the table window
Application.CommandBars("MainMenuBar").Enabled = True
'show my bar
DoCmd.ShowToolbar "MainMenuBar"
Application.CommandBars.DisableAskAQuestionDropdown = True
'shows the askquestion in toolbar
Application.CommandBars.DisableCustomize = False
'allows customizing again
errorhandler:
If Err.Number = 0 Then
Else
MsgBox (Err.Description)
End If
End Function