Excel Hide/Show all tabs on Ribbon except custom tab

后端 未结 6 1213
别跟我提以往
别跟我提以往 2020-12-03 05:58

How can I hide and show all the standard Excel ribbon tabs using VBA (not XML). I do not want to hide the whole ribbon (as is asked here: VBA minimize ribbon in Excel) just

6条回答
  •  无人及你
    2020-12-03 06:47

    First, open the Excel sheet which you want hide the ribbon tab on, then press Alt+F11. Insert new code module and add following code:

    Private Sub hide()
        Application.ExecuteExcel4Macro "Show.ToolBar(""Ribbon"",False)
    End sub
    

提交回复
热议问题