We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Concatenation issue - multiple pdf file into a single file

I need some help.

I am trying to merge multiple single page PDF files into a single PDF. My issue is coming for PDFs that have form data. When I look at the merged document, portions of the form data is missing.

I have tried using a couple of methods:

Aspose.Pdf.Facades.PdfPageEditor(); -- Added pages

Aspose.Pdf.Facades.PdfEditor(); -- Used concatenate

Hi John,


Thanks for your inquiry. Can you please share your sample documents here? So we will test the scenario at our end and will provide you information accordingly.

Sorry for the inconvenience faced.

Best Regards,

I am trying to arrange to procure some non-production documents that I can have you test with.

Found another product that seems to solve the issue.

Will still want Aspose's input on what can be done differently.

Forwarded the documents to the Aspose member.

Hi John,


We are testing the scenario and will get back to you soon.

Hi John,


Thanks for your inquiry. Please check following code snippet and the documentation link for concatenating the PDF documents. Hopefully it will serve the purpose.

string[] pdfFiles = Directory.GetFiles(@“E:/Data/490/”, “*.pdf”);
Document doc = new Document();
Document doc1;
for (int i = 0; i<pdfFiles.Length;i++ )
{
doc1 = new Document(pdfFiles[i]);
doc.Pages.Add(doc1.Pages);
}
doc.Save(myDir+“Concat_out.pdf”);

Please feel free to contact us for any further assistance.

Best Regards,