musicgold
11-21-2010, 08:37 AM
Hi,
I have made a macro that allows me to Print Preview a Word page. I have assigned a key combination to the macro and am able to switch between the regular view and print preview. However, I am struggling with the following two issues. Please see my code below.
1. Focus page changes. When I get back to the normal view, the focus goes back to the page where I started the print preview mode. So in a 10 page document, if I start print preview at page 1 and scroll down to page 5 and then notice some error and switch back to the regular mode to edit, Word takes me back to page 1. I want to be able to stay on page 5.
2. Print preview starts at the begining of the page. Print preview always shows the start of the page. For example, I am at the end of a page and switch to the print preview mode, Word displays the beginning of the page, so I have to scroll to the end of the page. I want it to show me the spot on the page where I started print preview.
Can this be done ?
If (Application.PrintPreview = True) Then
Application.PrintPreview = fales
Exit Sub
End If
With ActiveWindow.View
.Type = wdPrintPreview
.Zoom.Percentage = 120
End With
Thanks,
MG.
Cross listed at http://www.mrexcel.com/forum/showthread.php?t=510302
I have made a macro that allows me to Print Preview a Word page. I have assigned a key combination to the macro and am able to switch between the regular view and print preview. However, I am struggling with the following two issues. Please see my code below.
1. Focus page changes. When I get back to the normal view, the focus goes back to the page where I started the print preview mode. So in a 10 page document, if I start print preview at page 1 and scroll down to page 5 and then notice some error and switch back to the regular mode to edit, Word takes me back to page 1. I want to be able to stay on page 5.
2. Print preview starts at the begining of the page. Print preview always shows the start of the page. For example, I am at the end of a page and switch to the print preview mode, Word displays the beginning of the page, so I have to scroll to the end of the page. I want it to show me the spot on the page where I started print preview.
Can this be done ?
If (Application.PrintPreview = True) Then
Application.PrintPreview = fales
Exit Sub
End If
With ActiveWindow.View
.Type = wdPrintPreview
.Zoom.Percentage = 120
End With
Thanks,
MG.
Cross listed at http://www.mrexcel.com/forum/showthread.php?t=510302