Hello,
The company I am working for has purchased Aspose PDF Generator for creating PDF files from HTML and XSL-FO. We are having decent success with HTML, but the fidelity of the XSL-FO documents being generated seems very poor. At a previous company I used IBEX PDF Geneartor with great success, so I ran our FO documents through an evaluation version of IBEX and was able to generate the PDF I was expecting. I’m hoping you can help me get Aspose to generate the same quality PDF.
Please see the attached PDF files (one from Aspose, and another from IBEX) along with the FO document I used with each product. The supporting image files are also attached.
Hi Kyle,
Thanks for your reply Tilal. Does this mean that I could expect a resolution in a few days, a few weeks, or that I’ll have to wait until a future version update? This is very concerning to me because Aspose states in the product specification that PDF Generator supports XSL-FO. The FO document I submitted in this post was very basic and should present no problem to any software claiming to support XSL-FO.
Hi Kyle,
Is there any update / ETA on when this might be fixed? I am also running into the exact issue reported here.
Hi Kyle,
Hi Kyle,
Thanks for your patience.
The development team has further investigated the issue PDFNEWNET-37305 reported earlier. As per our observations, the issue seems to be related to incorrect input XSLFO (and currently, in such cases, an exception is generated). We have also implemented a feature to generate meaningful exceptions when such issues occur, so that users get a clear indication about what’s wrong in the source XSLFO document, instead of getting confused about whether it’s an issue with their source file or a problem occurring in our API.
Please note that the resource document contains incorrectly formatted fo:table-cell (line 54). According to the specification at http://www.w3.org/TR/xsl/#fo_table-cell, a table cell cannot directly contain fo:inline (see http://www.w3.org/TR/xsl/#fo_inline) elements. We have added a special handler for such exceptions to get more correct information about incorrectly formatted objects. Please note that if you fix your input file in accordance with the specification of xsl-fo, the document will be converted properly.
In order to get a result file with images, place the ‘/images’ folder with referenced images from the attached original set of input files (‘Aspose-XSL-FO-Issue.zip’) in the same directory as the input XslFo file. I have attached the corrected XSLFO file as 37305_corrected.fo
(please rename the file from .txt
to .fo
), along with the resultant PDF generated from the same file.
Also, please note that it is necessary to use the new XSLFO to PDF conversion engine.
Aspose.Pdf.XslFoLoadOptions options = new Aspose.Pdf.XslFoLoadOptions();
options.UseOldXslFoEngine = false;
string inFile = @"F:\ExternalTestsData\37305_corrected.fo";
Aspose.Pdf.Document newDoc = new Aspose.Pdf.Document(inFile, options);
string outPdfFile = @"F:\ExternalTestsData\37305_output.pdf";
newDoc.Save(outPdfFile);
The issues you have found earlier (filed as PDFNEWNET-37305) have been fixed in Aspose.Pdf for .NET 10.0.0.
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.