Xceed Words for .NET v3.0 Documentation
DifferentFirstPage Property (Document)
Example 


Xceed.Document.NET Assembly > Xceed.Document.NET Namespace > Document Class : DifferentFirstPage Property
Gets or sets if the first page of the first Section in this Document uses an independent Header and Footer.
Syntax
'Declaration
 
Public Property DifferentFirstPage As Boolean
'Usage
 
Dim instance As Document
Dim value As Boolean
 
instance.DifferentFirstPage = value
 
value = instance.DifferentFirstPage
public bool DifferentFirstPage {get; set;}

Property Value

true if the first page of the first Section uses an independant Header and Footer, otherwise false.
Example
// Create a document.
using (var document = DocX.Create(@"Test.docx"))
{
   // Add header support to this document.
   document.AddHeaders();

   // The header used for the first page of this document.
   Header first = document.Headers.first;

   // Force the document to use a different header for first page.
   document.DifferentFirstPage = true;

   // Content can be added to the Headers in the same manor that it would be added to the main document.
   Paragraph p = first.InsertParagraph();
   p.Append("This is the first pages header.");

   // Save all changes to this document.
   document.Save();
}// Release this document from memory.
Requirements

Target Platforms: Windows 11, Windows 10, Windows 7, Windows, 11, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Document Class
Document Members