bruntonomo
Board Regular
- Joined
- Jul 29, 2018
- Messages
- 67
- Office Version
- 365
- 2016
- Platform
- Windows
I understand this is an Excel forum, but I just came across something related to what I'm trying to do in Word through Google on this forum, and I'm hoping people continue to be extremely helpful here. This forum has been a life force for me in completing projects.
I am trying to craft a VBA code that will automatically accomplish the following things when opening a document in Word 2013: Turn OFF Ctrl+Click, turn ON Read Only, turn ON navigation pane, and turn OFF Reading Layout and/or turn ON Print Layout view.
This document is a procedures manual that I do not want employees changing (thus read only). However, when turning on read only, it blows up the document in reading layout. In print layout, it's fine. The navigation pane is a major part of navigating the large document. Turning off ctrl+click makes it so that less savvy Word users can simply click links.
I am not experienced in VBA at all. I have managed to gather a few VBA expressions, but am not sure how to put them all together. Any help would be majorly appreciated!
I am trying to craft a VBA code that will automatically accomplish the following things when opening a document in Word 2013: Turn OFF Ctrl+Click, turn ON Read Only, turn ON navigation pane, and turn OFF Reading Layout and/or turn ON Print Layout view.
This document is a procedures manual that I do not want employees changing (thus read only). However, when turning on read only, it blows up the document in reading layout. In print layout, it's fine. The navigation pane is a major part of navigating the large document. Turning off ctrl+click makes it so that less savvy Word users can simply click links.
I am not experienced in VBA at all. I have managed to gather a few VBA expressions, but am not sure how to put them all together. Any help would be majorly appreciated!
Code:
[COLOR=#000000][FONT=monospace]ActiveDocument.ActiveWindow.View.ReadingLayout = [/FONT][/COLOR][COLOR=#07704A][FONT=monospace]False
CommandBars("Navigation").Visible = True
With ActiveWindow.View
.ReadingLayout = False
.Type = wdPrintView
End With
Private Sub Document_Open()
Options.CtrlClickHyperlinkToOpen = False
End Sub
[/FONT][/COLOR]
Last edited: