Printing current view or page does not work from VBA

A

Andy

If I have a diagram with several pages. Calling the PrintOut method on
the document and specifying visPrintCurrentView or
visPrintCurrentPage always prints the first page regardless of which
page is the currently active page.

The only way I have found of printing the current page from VBA is by
using the print method. However, with a large diagrams this is not
ideal as I really need to be printing the users current view.

Any suggestions?
 
J

JuneTheSecond

I've recorded a mcro, but it printout all of a page,
so I checked and changed "PrintRange:=visPrintArea"
into "PrintRange:=visPrintCurrentView", in Visio2003.

Application.ActiveDocument.PrintOut PrintRange:=visPrintCurrentView, _
ScaleCurrentViewToPaper:=True, _
PrinterName:="Microsoft Office Document Image Writer"
 
A

Andy

I'm using the PrintOut method. However, if my document has multimple
pages and I call the method when any page other than the first pages is
active, the first page is always printed. i.e. I can't get it to print
page 2 onwards.
 
J

JuneTheSecond

I cannot. neither. An alternative might be to make another drawing that has
just one page and that has the copy of your view on the page.
 
Top