Hello,
as in Thread Missing assemblies mentioned does Aspose.Pdf 17.1 and newer throw the Assemly Aspose.Font missing error.
We updated all the dll’s to the newest version (see below), but due to the problem mentioned above, we have to use an older version of Aspose.Pdf.
Unfortunytely, from version 16.10 on, a FileNotFoundException is thrown, because the Aspose.HTML assemly is missing, when we load an HTML document into an Aspose.Pdf document, including an HTMLLoadOption to define a CustomLoaderOfExternalResources:
Aspose.Pdf.HtmlLoadOptions htmlOptions = new Aspose.Pdf.HtmlLoadOptions(folderUrl);
htmlOptions.CustomLoaderOfExternalResources = uri => { //handling of referenced files };
Aspose.Pdf.Document htmlDocument = new Aspose.Pdf.Document(memoryStream, htmlOptions) { IgnoreCorruptedObjects = true };
I tested ALL versions starting from 11.2.0 to 16.12.0 regarding both missing assembly errors - the result:
we have to use the Aspose.Pdf 12.0.0 version, but this version does not render tables correctly (see attachment - the blackening in the screenshot is due to data protection).
So, right now, our only possibility to convert an HTML file into PDF is to use Aspose.PDF version 12.0.0, including the table rendering issue…that is really, really frustrating!
.Net 3.5, SharePoint 2010, Windows Server 2008 R2
Aspose.Pdf 12.0.0.0
Aspose.Cells 17.5.0.0
Aspose.Email 17.4.0.0
Aspose.Imaging 17.4.0.0
Aspose.Slides 17.4.0.0
Aspose.Words 17.5.0.0
Hello Bea,
Thanks for the fast reply.
No, I did not. When was it released and why didn’t you inform about it in this thread?
Missing assemblies
And the problem is not fixed completly but “to many extents”? Could you please elaborate that (where/when is it not working).
But more important - how can I convert large text (->link below) and XML files into PDF? It seems that you removed the Aspose.Pdf.Generator namespace in 17.5.
https://docs.aspose.com/display/pdfnet/How+to+Convert+a+text+file+to+PDF#HowtoConvertatextfiletoPDF-ConvertingLargeTextfilestoPDF
Hi Bea,
bea.grosse-venhaus:
No, I did not. When was it released and why didn’t you inform about it in this thread?
Missing assemblies
bea.grosse-venhaus:
And the problem is not fixed completly but “to many extents”? Could you please elaborate that (where/when is it not working).
bea.grosse-venhaus:
But more important - how can I convert large text (->link below) and XML files into PDF? It seems that you removed the Aspose.Pdf.Generator namespace in 17.5.
System.IO.TextReader tr = new StreamReader(dataDir + “testtext.txt”, Encoding.Default, true);<o:p></o:p>
Aspose.Pdf.Document doc = new Aspose.Pdf.Document();<o:p></o:p>
Page page = doc.Pages.Add();<o:p></o:p>
String strLine;<o:p></o:p>
while ((strLine = tr.ReadLine()) != null)<o:p></o:p>
{<o:p></o:p>
Aspose.Pdf.Text.TextFragment text = new Aspose.Pdf.Text.TextFragment(strLine);<o:p></o:p>
page.Paragraphs.Add(text);<o:p></o:p>
}<o:p></o:p>
doc.Save(dataDir + “TexttoPDF_out.pdf”);<o:p></o:p>
tr.Close();<o:p></o:p>