Open valimaties opened 1 year ago
Hi,
for 2) Page Numbering, if you want each page number to start at 1 for each section of the document, you can do like that: ` var doc = DocX.Create( "test.docx" ); doc.InsertParagraph( "First Paragraph" );
doc.InsertSectionPageBreak();
doc.InsertParagraph( "Second Paragraph" ).InsertPageBreakAfterSelf();
doc.InsertParagraph( "new Paragraph of second section" );
doc.InsertSectionPageBreak();
doc.InsertParagraph( "Third Paragraph" );
foreach( var section in doc.Sections )
{
section.PageNumberType = new PageNumberType() { PageNumberStart = 1 };
}
doc.AddHeaders();
doc.Headers.Odd.InsertParagraph( "Page " ).AppendPageNumber( PageNumberFormat.normal ).Append( " of " ).AppendPageCount( PageNumberFormat.normal, true );
doc.Save();`
If you still have issues with page numbers, please send a sample showing the issue.
Thank you
Hi. I have two issues about Section's page counting. I don't know if these are issues from my MS Office 2019 or they are from this library: