PDA

View Full Version : Solved: What is PageSetup-MultiplePages property?



Adamski
05-28-2009, 06:46 AM
Hi,

Just wondering how to read the [Page Setup]-[Multiple pages:] dropdown box to a variable in Word 2003. There dosen't seem to be such a property in the PageSetup object to return the possible values: Normal, Mirror Margins, 2 pages per sheet, Book fold.

There is a boolean [TwoPagesOnOne] but what about finding out if it is set to "Normal"?

Thanks

fumei
05-28-2009, 08:57 AM
It is Normal if all the other possible attribute are False.

.MirrorMargins = False
.TwoPagesOnOne = False
.BookFoldPrinting = False
.BookFoldRevPrinting = False
means it is Normal.

.MirrorMargins = False
.TwoPagesOnOne = True
.BookFoldPrinting = False
.BookFoldRevPrinting = False
...or any other attribute (such as TwoPagesOnOne) = True...then it is NOT Normal.

Normal means all the attributes are False. There is no "Normal" property. Normal is determined (by Word) logically - all the possible choices are False.

Put another way, when you select Normal manually, in the dialog, you are - in fact - explicitly setting:

.MirrorMargins = False
.TwoPagesOnOne = False
.BookFoldPrinting = False
.BookFoldRevPrinting = False

Put another way: Multiple pages is NOT a property of PageSetup. So it can not be put into a variable...because it does not exist.

"but what about finding out if it is set to "Normal"?

Technically, it is never set to Normal. There is no "it" to set. You can easily see this if you record a macro changing things for Multiple pages, and then looking at the code. There is no Normal. There are the Booleans for MirrorMargins etc. But no Normal.

Why do you want to get a variable for this? You could get a variable to (sort of) describe the state of the Booleans through nested logic, but why?

Adamski
06-01-2009, 03:14 AM
Cheers, that's what I thaught I would have to do. I wanted to know this state in order to test if the gutter is set to 'top', but it turns out that that selecting any other page layout automatically changes the GutterPos property from top if it is set. So it is not posible for it to be set in any other layout other than normal anyway.

Thanks