Hi. Really impressed with PDFSharp and have managed to get it to do what I want (merging pdf files together) but I can't figure out how to work with MigraDoc to number pages. I am using VB.Net
I found the code to number pages at
viewtopic.php?p=1712#p1712Code:
Dim style As Style
pdfDocument = New Document()
[.......]
Dim section As Section
Dim r As Row
Dim c As Column
section = pdfDocument.AddSection()
[...........]
'Aggiungo il numero di pagina in basso a destra
p = New Paragraph()
p.AddText("Pag. ")
p.AddPageField()
p.AddText(" di ")
p.AddNumPagesField()
p.Format.Alignment = ParagraphAlignment.Right
section.Footers.Primary.Add(p)
And I want to number pages on an existing PDF.
I have:
Code:
For Each page As PdfPage In readDocument.Pages
document.AddPage(page)
Next page
and I'd like to number each page in that For/Next routine. How do I pass the page to MigraDoc and number it?
Thanks.