scttsmn
scttsmn

Reputation: 35

PowerPoint VBA to Hide Ribbon

I want to use VBA to hide the ribbon in the "Normal" view and make it inaccessible, similar to how the ribbon is not displayed or accessible in the "Reading" view.

I have used the following method in Excel, but I am unaware of any similar method for PowerPoint:

Application.ExecuteExcel4Macro "Show.Toolbar(""Ribbon"",false)

I am aware that the "Visible" property of other command bars can be set as follows:

CommandBars("Status Bar").Visible = False

However, the "Visible" property cannot be set for the the "Ribbon" in the same fashion. Specifically, the following code will not hide the Ribbon or make it inaccessible in PowerPoint:

CommandBars("Ribbon").Visible = False

Is there any alternate method for PowerPoint to achieve the same effect as the Excel VBA code above?

Upvotes: 1

Views: 484

Answers (1)

z32a7ul
z32a7ul

Reputation: 3777

Try this:

CommandBars.ExecuteMso "MinimizeRibbon"

The above minimizes the Ribbon. To hide it completely:

CommandBars.ExecuteMso "HideRibbon"

Upvotes: 1

Related Questions