Search code examples
vbamacosms-word

Show styles pane in Word for Mac VBA


I have this code to show the styles pane in Word for Windows:
Application.TaskPanes(wdTaskPaneFormatting).Visible = True

Unfortunately this doesn't work in Word for Mac. I can't record a macro (it shows no code).
Can someone please help me with the VBA to show the styles pane in Word for Mac?

Thank you in advance.

Kem


Solution

  • Application.CommandBars("Styles").Visible=True

    Not having Word for the Mac, I nevertheless suggest that you try:

    Application.CommandBars("Styles").Visible=True