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

Free Support Forum - aspose.com

Quality of PDFs (Word vs Cells) and embedded XLSX


We’re using the Total suite to create PDFs. We use “Words” to convert tokenized (LINQ) Word docs and save as PDF. We’ve been happy with the quality of the generated PDFs.

We have a new document (docx) containing a relatively complex table (eg conditional logic, multiple pages, combined column headings…) and the LINQ syntax for populating the table became cumbersome.

I created a spreadsheet (xlsx) in Excel, opened/filled data using Cells, and saved as PDF. The intent was to merge with PDFs created from DOCX file(s).

The PDFs generated using Words seem to be higher quality/cleaner and easier to manage the table/page layout than with the Cells conversion to PDF.

Q: Should I expect similar quality PDFs from Words and Cells?
I don’t have as much experience with Cells, so it might user ignorance.

Q: Is it possible to prepare the xlsx and embed in the docx using Words?
This would allow me to use Words to create the PDF.

Q: Might there be any benefit to opening/loading the xlsx, saving to temporary xlsx file, loading the new file, and then saving as PDF?
I assume not, but I’m starting to grasp…

General issues I’m debugging include:

  • Inability to successfully use repeat headers on multiple page sheets
    Tried: pageSetup.setPrintTitleColumns("$A:$I") and pageSetup.setPrintTitleRows("$1:$2")
  • Row/Column headings (A…Z) viewable in PDF
  • Headers/Footers harder to manage in Cells
  • Dashed vs solid lines for cell borders

I expect you’re going to ask me for more concrete examples of “quality”. I’m working on it, but wanted some general guidance before the weekend.


Thanks for your query.

Well both the products use different engines for rendering, therefor you may feel some difference in the results. However if you face some problem, you may share sample data and code for our analysis.

You may please try following sample code to embed Excel file into Word file.
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
Stream memoryStream = File.OpenRead(MyDir + “Worksheet in Test.xls”);
Shape oleObject = builder.InsertOleObject(memoryStream, “Excel.Sheet.8”, false, Image.FromFile(MyDir + “SheetImage.jpg”));
doc.Save(MyDir + @“out.docx”);

It may not produce different results as you commented also.

All the issues you are facing require sample code and template files along with the output file created by program and also expected output file created by Excel/Word for our analysis.