Page.PageType Property (Publisher)
Returns a PbPageType constant that represents the page type. Read-only.
Syntax
expression .PageType
expression A variable that represents a Page object.
Return Value
PbPageType
Remarks
The PageType property value can be one of the following PbPageType constants declared in the Microsoft Publisher type library.
pbPageLeftPage |
pbPageMasterPage |
pbPageRightPage |
pbPageScratchPage |
Example
This example adds a shape on alternating corners of each page in the active publication.
Sub GetPageType()
Dim pgCount As Page
For Each pgCount In ActiveDocument.Pages
If pgCount.PageType = pbPageLeftPage Then
pgCount.Shapes.AddShape Type:=msoShapeOval, _
Left:=50, Top:=50, Width:=50, Height:=50
ElseIf pgCount.PageType = pbPageRightPage Then
pgCount.Shapes.AddShape Type:=msoShapeOval, _
Left:=512, Top:=50, Width:=50, Height:=50
End If
Next
End Sub