Search code examples
c#annotationspdfsharp

PDFSharp losing annotations


Hello I am using the latest pre release version of PDFSharp and I am concatenating several documents. However, when I add the pages it is losing the annotation. Any idea why?

When I get the file like below, it has the annotation.

PdfDocument inputDocument1 = PdfReader.Open(fromDirectory, PdfDocumentOpenMode.Import);

But, when I go to add it to the overall document, like below, it loses the annotation.

page = outputDocument.AddPage(page);

Any help on this would be greatly appreciated!


Solution

  • It turns out that PDFSharp 1.50.4000-beta 3b has a bug, so I backed up to version 1.32.3057 and it started working.