Sorry for the delay, I got side tracked on other issues.
The following code should do what you want:
Public Sub PageSizeSet()
' Set the page size for all pages
Dim PagObj As Visio.Page
For Each PagObj In ActiveDocument.Pages
' Setup 1 - two portrait legal
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesScaleX).FormulaU = "1"
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesScaleY).FormulaU = "1"
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesPageOrientation).FormulaU = "1"
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesPaperKind).FormulaU = "5"
' Setup 2 - one landscape tabloid
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesPageOrientation).FormulaU = "2"
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesPaperKind).FormulaU = "3"
' Setup 3 - landscape letter shrink to fit
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesOnPage).FormulaU = "1"
PagObj.PageSheet.CellsSRC(visSectionObject, visRowPrintProperties,
visPrintPropertiesPaperKind).FormulaU = "1"
Next
End Sub
You will have to make three copies and do some deletion so that each block
is in it's own Sub.
John... Visio MVP
Need stencils or ideas?
http://www.mvps.org/visio/3rdparty.htm
Need VBA examples?
http://www.mvps.org/visio/VBA.htm
Common Visio Questions
http://www.mvps.org/visio/common_questions.htm