View Single Post
 
Old 01-18-2023, 03:25 PM
NitroPress NitroPress is offline Windows 11 Office 2016
Novice
 
Join Date: Nov 2019
Posts: 23
NitroPress is on a distinguished road
Default Set "Styles in Current Doc" with macro?

I have a nifty little macro that sets up a document workspace the way I like it — Nav and Style panes glued to the edges, and a designated zoom factor:


Code:
Sub FullOpenDoc()
'
' Open doc with Nav and Styles panels, to selected Zoom
'

ActiveWindow.DocumentMap = True

With Application
.TaskPanes(wdTaskPaneFormatting).Visible = True
.CommandBars("Styles").Position = msoBarRight
.CommandBars("Styles").Width = 350
End With

' Set zoom value to that from your adjusted zoom slider

ActiveWindow.ActivePane.View.Zoom.Percentage = 112

End Sub
I'd like to add a function to set the Styles display (under the Options button) to "In current document" but I've failed to record a working sequence for this. Anyone have a script line for that?
Reply With Quote