Hello,
We’ve changed from ApacheFOP in Java to AsposePDF.Net.
The filesize of the pdf-files generated by ApacheFOP were around 5 KB.
The filesize of the pdf-files generated by AsposePDF are around 80-90 KB.
I’ve included following optimization code, which i’ve found in the forum, but it didn’t helped.
The filesize is still the same (actually it’s a little bit larger with optimization?)
It’s important for us to minimize the filesize as small as possible.
Do you have any ideas?
Thank you!
Document m_asposepdf = new Document(inStr, xslLoadOptions);
//ImageCompressionOptions ImageCompressionOptions = new ImageCompressionOptions();
//ImageCompressionOptions.CompressImages = true;
//ImageCompressionOptions.ImageQuality = 12;
//ImageCompressionOptions.ResizeImages = true;
//m_asposepdf.OptimizeResources(new OptimizationOptions()
//{
// LinkDuplcateStreams = true,
// RemoveUnusedObjects = true,
// AllowReusePageContent = true,
// RemoveUnusedStreams = true,
// UnembedFonts = false
//});
//m_asposepdf.Optimize();
MemoryStream outStream = new MemoryStream();
m_asposepdf.Save(outStream);
Sincerly,
Robin