PageSetup Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Page Setup.
This class is available in Office 2007 and above.
When the object is serialized out as xml, it's qualified name is c:pageSetup.
[DocumentFormat.OpenXml.OfficeAvailability(DocumentFormat.OpenXml.FileFormatVersions.Office2007)]
[DocumentFormat.OpenXml.SchemaAttr(11, "pageSetup")]
public class PageSetup : DocumentFormat.OpenXml.OpenXmlLeafElement
public class PageSetup : DocumentFormat.OpenXml.OpenXmlLeafElement
[DocumentFormat.OpenXml.SchemaAttr(11, "pageSetup")]
public class PageSetup : DocumentFormat.OpenXml.OpenXmlLeafElement
[DocumentFormat.OpenXml.SchemaAttr("c:pageSetup")]
public class PageSetup : DocumentFormat.OpenXml.OpenXmlLeafElement
[DocumentFormat.OpenXml.SchemaAttr("c:pageSetup")]
public class PageSetup : DocumentFormat.OpenXml.TypedOpenXmlLeafElement
[DocumentFormat.OpenXml.OfficeAvailability(DocumentFormat.OpenXml.FileFormatVersions.Office2007)]
public class PageSetup : DocumentFormat.OpenXml.OpenXmlLeafElement
[<DocumentFormat.OpenXml.OfficeAvailability(DocumentFormat.OpenXml.FileFormatVersions.Office2007)>]
[<DocumentFormat.OpenXml.SchemaAttr(11, "pageSetup")>]
type PageSetup = class
inherit OpenXmlLeafElement
type PageSetup = class
inherit OpenXmlLeafElement
[<DocumentFormat.OpenXml.SchemaAttr(11, "pageSetup")>]
type PageSetup = class
inherit OpenXmlLeafElement
[<DocumentFormat.OpenXml.SchemaAttr("c:pageSetup")>]
type PageSetup = class
inherit OpenXmlLeafElement
[<DocumentFormat.OpenXml.SchemaAttr("c:pageSetup")>]
type PageSetup = class
inherit TypedOpenXmlLeafElement
[<DocumentFormat.OpenXml.OfficeAvailability(DocumentFormat.OpenXml.FileFormatVersions.Office2007)>]
type PageSetup = class
inherit OpenXmlLeafElement
Public Class PageSetup
Inherits OpenXmlLeafElement
Public Class PageSetup
Inherits TypedOpenXmlLeafElement
- Inheritance
- Inheritance
- Attributes
Remarks
[ISO/IEC 29500-1 1st Edition]
pageSetup (Page Setup)
This element defines the page setup for the chart.
[Example: The following example shows the pageSetup element for A0 paper, printed in black and white, with graphics:
<pageSetup blackAndWhite="true" draft="false" paperHeight="1189" paperWidth="841" paperUnits="mm" />
end example]
Parent Elements |
---|
printSettings (§21.2.2.148) |
Attributes | Description |
---|---|
blackAndWhite (Black and White) | Specifies the page shall print in black and white. The possible values for this attribute are defined by the W3C XML Schema boolean datatype. |
copies (Copies) | Specifies the number of copies that shall be printed. The possible values for this attribute are defined by the W3C XML Schema unsignedInt datatype. |
draft (Draft) | Specifies the page shall be printed in draft mode. The possible values for this attribute are defined by the W3C XML Schema boolean datatype. |
firstPageNumber (First Page Number) | Specifies the page number. The possible values for this attribute are defined by the W3C XML Schema unsignedInt datatype. |
horizontalDpi (Horizontal DPI) | Specifies the horizontal resolution to print in dots per inch. The possible values for this attribute are defined by the W3C XML Schema int datatype. |
orientation (Orientation) | Specifies the orientation of the paper. The possible values for this attribute are defined by the ST_PageSetupOrientation simple type (§21.2.3.32). |
paperHeight (Paper Height) | Height of custom paper as a number followed by a unit identifier. [Example: 297mm, 11in end example] When paperHeight and paperWidth are specified, paperSize shall be ignored. The possible values for this attribute are defined by the ST_PositiveUniversalMeasure simple type (§22.9.2.12). |
paperSize (Page Size) | Specifies the paper size according to the following table. Paper Size Width Height Value Letter paper 8.5 in. 11 in. 1 Legal paper 8.5 in. 14 in. 5 Standard paper 10 in. 11 in. 45 Standard paper 10 in. 14 in. 16 Standard paper 11 in. 17 in. 17 Standard paper 15 in. 11 in. 46 Standard paper 9 in. 11 in. 44 SuperA/SuperA/A4 paper 227 mm 356 mm 57 A2 paper 420 mm 594 mm 66 A3 paper 297 mm 420 mm 8 A3 extra paper 322 mm 445 mm 63 A3 extra transverse paper 322 mm 445 mm 68 A3 transverse paper 297 mm 420 mm 67 A4 paper 210 mm 297 mm 9 A4 extra paper 236 mm 322 mm 53 A4 plus paper 210 mm 330 mm 60 A4 transverse paper 210 mm 297 mm 55 A4 small paper 210 mm 297 mm 10 A5 paper 148 mm 210 mm 11 A5 extra paper 174 mm 235 mm 64 A5 transverse paper 148 mm 210 mm 61 SuperB/SuperB/A3 paper 305 mm 487 mm 58 B4 paper 250 mm 353 mm 12 B5 paper 176 mm 250 mm 13 B5 extra paper 201 mm 276 mm 65 JIS B5 transverse paper 182 mm 257 mm 62 C paper 17 in. 22 in. 24 D paper 22 in. 34 in. 25 #10 envelope 4.125 in. 9.5 in. 20 #11 envelope 4.5 in. 10.375 in. 21 #12 envelope 4.75 in. 11 in. 22 #14 envelope 5 in. 11.5 in. 23 #9 envelope 3.875 in. 8.875 in. 19 B4 envelope 250 mm 353 mm 33 B5 envelope 176 mm 250 mm 34 B6 envelope 176 mm 125 mm 35 C3 envelope 324 mm 458 mm 29 C4 envelope 229 mm 324 mm 30 C5 envelope 162 mm 229 mm 28 C6 envelope 114 mm 162 mm 31 C65 envelope 114 mm 229 mm 32 DL envelope 110 mm 220 mm 27 Invite envelope 220 mm 220 mm 47 Italy envelope 110 mm 230 mm 36 Monarch envelope 3.875 in. 7.5 in.). 37 6 3/4 envelope 3.625 in. 6.5 in. 38 E paper 34 in. 44 in. 26 Executive paper 7.25 in. 10.5 in. 7 German legal fanfold 8.5 in. 13 in. 41 German standard fanfold 8.5 in. 12 in. 40 US standard fanfold 14.875 in. 11 in. 39 Folio paper 8.5 in. 13 in. 14 B4 250 mm 353 mm 42 Japanese double postcard 200 mm 148 mm 43 Ledger paper 17 in. 11 in. 4 Legal extra paper 9.275 in. 15 in. 51 Letter extra paper 9.275 in. 12 in. 50 Letter extra transverse paper 9.275 in. 12 in. 56 Letter plus paper 8.5 in. 12.69 in. 59 Letter transverse paper 8.275 in. 11 in. 54 Letter small paper 8.5 in. 11 in. 2 Note paper 8.5 in. 11 in. 18 Quarto paper 215 mm 275 mm 15 Statement paper 5.5 in. 8.5 in. 6 Tabloid paper 11 in. 17 in. 3 Tabloid extra paper 11.69 in. 18 in. 52 When paperHeight, paperWidth, and paperUnits are specified, paperSize should be ignored. The possible values for this attribute are defined by the W3C XML Schema unsignedInt datatype. |
paperWidth (Paper Width) | Width of custom paper as a number followed by a unit identifier. [Example: 21cm, 8.5in end example] When paperHeight and paperWidth are specified, paperSize shall be ignored. The possible values for this attribute are defined by the ST_PositiveUniversalMeasure simple type (§22.9.2.12). |
useFirstPageNumber (Use First Page Number) | Specifies to use the first page number instead of automatically generating a page number. The possible values for this attribute are defined by the W3C XML Schema boolean datatype. |
verticalDpi (Vertical DPI) | Specifies the vertical resolution to print in dots per inch. The possible values for this attribute are defined by the W3C XML Schema int datatype. |
[Note: The W3C XML Schema definition of this element’s content model (CT_PageSetup) is located in §A.5.1. end note]
� ISO/IEC29500: 2008.
Constructors
PageSetup() |
Initializes a new instance of the PageSetup class. |
Properties
BlackAndWhite |
Black and White Represents the following attribute in the schema: blackAndWhite |
ChildElements |
Gets all the child nodes of the current element. (Inherited from OpenXmlElement) |
Copies |
Copies Represents the following attribute in the schema: copies |
Draft |
Draft Represents the following attribute in the schema: draft |
ExtendedAttributes |
Gets all extended attributes (attributes not defined in the schema) of the current element. (Inherited from OpenXmlElement) |
Features |
Gets a IFeatureCollection for the current element. This feature collection will be read-only, but will inherit features from its parent part and package if available. (Inherited from OpenXmlElement) |
FirstChild |
Gets the first child of the OpenXmlElement element. Returns null (Nothing in Visual Basic) if there is no such OpenXmlElement element. (Inherited from OpenXmlElement) |
FirstPageNumber |
First Page Number Represents the following attribute in the schema: firstPageNumber |
HasAttributes |
Gets a value indicating whether the current element has any attributes. (Inherited from OpenXmlElement) |
HasChildren |
Gets a value that indicates whether the current element has any child elements. (Inherited from OpenXmlLeafElement) |
HorizontalDpi |
Horizontal DPI Represents the following attribute in the schema: horizontalDpi |
InnerText |
Gets or sets the concatenated values of the node and all of its children. (Inherited from OpenXmlElement) |
InnerXml |
Gets or sets the markup that only represents child elements of the current element. (Inherited from OpenXmlLeafElement) |
LastChild |
Gets the last child of the OpenXmlElement element. Returns null (Nothing in Visual Basic) if there is no such OpenXmlElement element. (Inherited from OpenXmlElement) |
LocalName | |
LocalName |
Gets the local name of the current element. (Inherited from OpenXmlElement) |
MCAttributes |
Gets or sets the markup compatibility attributes. Returns null if no markup compatibility attributes are defined for the current element. (Inherited from OpenXmlElement) |
NamespaceDeclarations |
Gets all the namespace declarations defined in the current element. Returns an empty enumerator if there is no namespace declaration. (Inherited from OpenXmlElement) |
NamespaceUri |
Gets the namespace URI of the current element. (Inherited from OpenXmlElement) |
OpenXmlElementContext |
Gets the OpenXmlElementContext of the current element. (Inherited from OpenXmlElement) |
Orientation |
Orientation Represents the following attribute in the schema: orientation |
OuterXml |
Gets the markup that represents the current element and all of its child elements. (Inherited from OpenXmlElement) |
PaperSize |
Page Size Represents the following attribute in the schema: paperSize |
Parent |
Gets the parent element of the current element. (Inherited from OpenXmlElement) |
Prefix |
Gets the namespace prefix of current element. (Inherited from OpenXmlElement) |
UseFirstPageNumber |
Use First Page Number Represents the following attribute in the schema: useFirstPageNumber |
VerticalDpi |
Vertical DPI Represents the following attribute in the schema: verticalDpi |
XmlQualifiedName |
Gets the qualified name of the current element. (Inherited from OpenXmlElement) |
XName |
Gets the qualified name of the current element. (Inherited from OpenXmlElement) |
Methods
AddAnnotation(Object) |
Adds an object to the current OpenXmlElement element's list of annotations. (Inherited from OpenXmlElement) |
AddNamespaceDeclaration(String, String) |
Adds a namespace declaration to the current node. (Inherited from OpenXmlElement) |
Ancestors() |
Enumerates all of the current element's ancestors. (Inherited from OpenXmlElement) |
Ancestors<T>() |
Enumerates only the current element's ancestors that have the specified type. (Inherited from OpenXmlElement) |
Annotation(Type) |
Get the first annotation object of the specified type from the current OpenXmlElement element. (Inherited from OpenXmlElement) |
Annotation<T>() |
Get the first annotation object of the specified type from the current OpenXmlElement element. (Inherited from OpenXmlElement) |
Annotations(Type) |
Gets a collection of annotations with the specified type for the current OpenXmlElement element. (Inherited from OpenXmlElement) |
Annotations<T>() |
Gets a collection of annotations with the specified type for the current OpenXmlElement element. (Inherited from OpenXmlElement) |
Append(IEnumerable<OpenXmlElement>) |
Appends each element from a list of elements to the end of the current element's list of child elements. (Inherited from OpenXmlElement) |
Append(OpenXmlElement[]) |
Appends each element from an array of elements to the end of the current element's list of child elements. (Inherited from OpenXmlElement) |
AppendChild<T>(T) |
Appends the specified element to the end of the current element's list of child nodes. (Inherited from OpenXmlElement) |
ClearAllAttributes() |
Clears all of the attributes, including both known attributes and extended attributes. (Inherited from OpenXmlElement) |
Clone() |
Creates a duplicate of the current node. (Inherited from OpenXmlElement) |
CloneNode(Boolean) |
Creates a duplicate of this node. |
Descendants() |
Enumerates all of the current element's descendants. (Inherited from OpenXmlElement) |
Descendants<T>() |
Enumerate all of the current element's descendants of type T. (Inherited from OpenXmlElement) |
Elements() |
Enumerates all of the current element's children. (Inherited from OpenXmlElement) |
Elements<T>() |
Enumerates only the current element's children that have the specified type. (Inherited from OpenXmlElement) |
ElementsAfter() |
Enumerates all of the sibling elements that follow the current element and have the same parent as the current element. (Inherited from OpenXmlElement) |
ElementsBefore() |
Enumerates all of the sibling elements that precede the current element and have the same parent as the current element. (Inherited from OpenXmlElement) |
GetAttribute(String, String) |
Gets an Open XML attribute with the specified tag name and namespace URI. (Inherited from OpenXmlElement) |
GetAttributes() |
Gets a list that contains a copy of all the attributes. (Inherited from OpenXmlElement) |
GetEnumerator() |
Returns an enumerator that iterates through the child collection. (Inherited from OpenXmlElement) |
GetFirstChild<T>() |
Finds the first child element in type T. (Inherited from OpenXmlElement) |
InsertAfter<T>(T, OpenXmlElement) |
Inserts the specified element immediately after the specified reference element. (Inherited from OpenXmlElement) |
InsertAfterSelf<T>(T) |
Inserts the specified element immediately after the current element. (Inherited from OpenXmlElement) |
InsertAt<T>(T, Int32) |
Inserts the specified element at the specified index in the current element's list of child elements. (Inherited from OpenXmlElement) |
InsertBefore<T>(T, OpenXmlElement) |
Inserts the specified element immediately before the specified reference element. (Inherited from OpenXmlElement) |
InsertBeforeSelf<T>(T) |
Inserts the specified element immediately before the current element. (Inherited from OpenXmlElement) |
IsAfter(OpenXmlElement) |
Determines if the current element appears after a specified element in document order. (Inherited from OpenXmlElement) |
IsBefore(OpenXmlElement) |
Determines if the current element appears before a specified element in document order. (Inherited from OpenXmlElement) |
LookupNamespace(String) |
Resolves the namespace prefix in the context of the current node. (Inherited from OpenXmlElement) |
LookupPrefix(String) |
Finds the corresponding prefix for a namespace uri in the current element scope. (Inherited from OpenXmlElement) |
NextSibling() |
Gets the OpenXmlElement element that immediately follows the current OpenXmlElement element. Returns null (Nothing in Visual Basic) if there is no next OpenXmlElement element. (Inherited from OpenXmlElement) |
NextSibling<T>() |
Gets the OpenXmlElement element with the specified type that follows the current OpenXmlElement element. Returns null (Nothing in Visual Basic) if there is no next OpenXmlElement. (Inherited from OpenXmlElement) |
PrependChild<T>(T) |
Inserts the specified element at the beginning of the current element's list of child elements. (Inherited from OpenXmlElement) |
PreviousSibling() |
Gets the OpenXmlElement element that immediately precedes the current OpenXmlElement element. Returns null (Nothing in Visual Basic ) if there is no preceding OpenXmlElement element. (Inherited from OpenXmlElement) |
PreviousSibling<T>() |
Gets the OpenXmlElement element with the specified type that precedes the current OpenXmlElement. Returns null (Nothing in Visual Basic) if there is no preceding OpenXmlElement element. (Inherited from OpenXmlElement) |
Remove() |
Removes the current element from its parent. (Inherited from OpenXmlElement) |
RemoveAllChildren() |
Removes all child elements of the current element. (Inherited from OpenXmlLeafElement) |
RemoveAllChildren<T>() |
Remove all of the current element's child elements that are of type T. (Inherited from OpenXmlElement) |
RemoveAnnotations(Type) |
Removes the annotations of the specified type from the current OpenXmlElement element. (Inherited from OpenXmlElement) |
RemoveAnnotations<T>() |
Removes the annotations with the specified type from the current OpenXmlElement element. (Inherited from OpenXmlElement) |
RemoveAttribute(String, String) |
Removes the attribute from the current element. (Inherited from OpenXmlElement) |
RemoveChild<T>(T) |
Removes the specified child element from the current element's list of child elements. (Inherited from OpenXmlElement) |
RemoveNamespaceDeclaration(String) |
Removes the namespace declaration for the specified prefix. Removes nothing if there is no prefix. (Inherited from OpenXmlElement) |
ReplaceChild<T>(OpenXmlElement, T) |
Replaces a child element with another child element in the current element's list of child elements. (Inherited from OpenXmlElement) |
SetAttribute(OpenXmlAttribute) |
Sets an attribute to the specified element. If the attribute is a known attribute, the value of the attribute is set. If the attribute is an extended attribute, the 'openxmlAttribute' is added to the extended attributes list. (Inherited from OpenXmlElement) |
SetAttributes(IEnumerable<OpenXmlAttribute>) |
Sets a number of attributes to the element. If an attribute is a known attribute, the value of the attribute is set. If an attribute is an extended attribute, the 'openxmlAttribute' is added to the extended attributes list. (Inherited from OpenXmlElement) |
WriteTo(XmlWriter) |
Saves the current node to the specified XmlWriter. (Inherited from OpenXmlElement) |
Explicit Interface Implementations
IEnumerable.GetEnumerator() | (Inherited from OpenXmlElement) |
IEnumerable<OpenXmlElement>.GetEnumerator() |
Returns an enumerator that iterates through the child collection. (Inherited from OpenXmlElement) |