Free Support Forum - aspose.com

PdfFileEditor removes highlights during split or extract

Hi, I'm using Aspose.PDF for .Net v6.2.0.

When I try to use PdfFileEditor to split an existing document that contains highlighting into individual pages, only the highlighting on the first page is retained. Any highlighting on page 2 or higher is stripped.

I have attached a sample source file and 2 different code techniques that I have tried. Firstly, the prefered methods is using SplitToPages:

 var fileEditor = new Aspose.Pdf.Facades.PdfFileEditor();
 var pageStreams = fileEditor.SplitToPages("source.pdf");
 for (int i = 0; i < pageStreams.Length; i++)
 {
   var outputFilename = string.Format("SplitPage{0}.pdf", i + 1);
   using (FileStream fs = new FileStream(outputFilename, FileMode.Create))
   {
     pageStreams[i].WriteTo(fs);
   }
 }
But I have also tried using the Extract method:
  var fileInfo = new Aspose.Pdf.Facades.PdfFileInfo("source.pdf");
  var fileEditor = new Aspose.Pdf.Facades.PdfFileEditor();
  for (int i = 1; i <= fileInfo.NumberOfPages; i++)
  {
    var outputFilename = string.Format("ExtractedPage{0}.pdf", i);
    fileEditor.Extract("source.pdf", new int[] { i }, outputFilename);
  }
This is quite urgent for us, as we are production ready with a new application and this bug will stop us from deploying.
Regards
Dave

Hi Dave,<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

Thank you for sharing the sample codes and template files.

We have found your mentioned issues after initial tests. Your issues have been registered in our issue tracking system with issue ids: PDFNEWNET-30893 and PDFNEWNET-30894. You will be notified via this forum thread regarding any update against your reported issues.

Sorry for the inconvenience caused,

Hello Dave,

Thanks for your patience. I am pleased to share that the issues reported earlier have been fixed and their hotfix will be included in upcoming release version. Please be patient and spare us little time. We apologize for your inconvenience.

The issues you have found earlier (filed as 30893 ;30894 ) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.

Tested the update, all good now.

Thanks