Prevent user to unhide Formula Bar

  • Thread starter Thread starter OMER
  • Start date Start date
O

OMER

Hola,

I'm trying to write code to prevent user to UNHIDE the Formula Bar. The
following command actually hides it:

Application.DisplayFormulaBar = False

but the user still can go to View menu and check the Formula Bar back.

I want it to hide it and prevent the user to unhide it as long as the
workbook is open.

Any suggestions are welcome.

Regards,
OMER
 
Do your users **need** to have access to the Ribbon (that is, is any access
they need provided by your code, a userform, etc.)? If not, we can remove
that as well...

Sub HideRibbonAndFormula()
ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",False)"
Application.DisplayFormulaBar = False
End Sub

Sub ShowRibbonAndFormula()
ExecuteExcel4Macro "SHOW.TOOLBAR(""Ribbon"",True)"
Application.DisplayFormulaBar = True
End Sub

I gave you a "show ribbon" macro so you can turn it back on again.
 
Back
Top