Spire.Presentation is a professional PowerPoint® compatible library that enables developers to create, read, write, modify, convert and Print PowerPoint documents. Get free and professional technical support for Spire.Presentation for .NET, Java, Android, C++, Python.

Fri Apr 16, 2021 5:18 pm

I need your help in resolving a problem I have encountered while using Spire.Presentation package.
We are using Pro edition, order info is below.

The problem is – after converting a PPTX presentation to PDF, the images embedded into presentation come out in poor quality.

The code generating the PDF:
Spire.Presentation.Presentation ppt = new Spire.Presentation.Presentation();
ppt.LoadFromStream(presentationStream, FileFormat.Pptx2007);
ppt.SaveToFile(outStream, FileFormat.PDF);

I am getting the same result when reading from files not streams.

Please advise the resolution, it is important that the image quality is not lost during export to PDF .

alexsa248
 
Posts: 4
Joined: Fri Apr 16, 2021 5:13 pm

Mon Apr 19, 2021 7:41 am

Hi,

Thank you for your inquiry.
I noticed that you shared your input PowerPoint file via email. I converted it with the latest Spire.Presentation Pack Hotfix Version:6.4.1, but did not reproduce your problem. The attachment is my output file. If you were using an old version, I suggest you use the latest one to try again. If your problem still occurs, to help further look into it, please provide your test environment, such as OS info (E.g. Windows7, 64bit) and region setting (E.g. China, Chinese). Meanwhile, please let us know your application target platform, such as .NET Framework 4.5.

Sincerely,
Annika
E-iceblue support team
User avatar

Annika.Zhou
 
Posts: 1643
Joined: Wed Apr 07, 2021 2:50 am

Mon Apr 19, 2021 8:21 pm

HI Annika,

Your output looks perfect, could you post the code you used to generate it?
Maybe I am missing some important options/settings?

Thanks,
Alex

alexsa248
 
Posts: 4
Joined: Fri Apr 16, 2021 5:13 pm

Tue Apr 20, 2021 11:02 am

Dear Alex,

I used the same code as yours.
Previously, I didn't know your test environment, so I did test on .NET Framework, the output was produced by this platform. According to you email description, I know your application is NETCore target. I indeed reproduced the poor quality image issue with same environment as yours (WinServer2016, NETCore). After investigation, I found your solution (manually manipulating Spire.Presentation package rather than adding package from NuGet Manager) is correct. That's because the DLL we uploaded on Nuget for NETCore actually is the one for NETStandard target. Using the NETCore dll instead of NETStandard dll could resolve the poor quality issue. Kindly note the NetCore dll have the following external references. Please make sure that you will install the three assemblies while manually manipulating Spire.Presentation package from NETCore folder. If there is any doubt, please feel free to write back.

System.Drawing.Common >= 4.5.0
System.Text.Encoding.CodePages >= 4.5.0
System.Security.Cryptography.Xml >=4.5.0

Sincerely,
Nina
E-iceblue support team
User avatar

Nina.Tang
 
Posts: 1182
Joined: Tue Sep 27, 2016 1:06 am

Tue Apr 20, 2021 4:10 pm

Hello Nina,

Thank you for the prompt investigation of my issue, I truly appreciate it!

Is there any chance your team will update the NuGet Spire.Presentation package in the public NuGet repo to include .Net Core 2.0 files anytime soon?

This would help people using .Net Core 2.* target frameworks.
Manually installing packages is time consuming and a source of errors.

Thanks Again,
Alex

alexsa248
 
Posts: 4
Joined: Fri Apr 16, 2021 5:13 pm

Wed Apr 21, 2021 2:49 am

Hello Alex,

Thanks for your feedback.
We uploaded the Spire.Office.NETCore package which contains netcore 2.0 / 3.0 dlls on Nuget, pelase install the Spire.Office.NETCore from NuGet Manager. If you have other question, please feel free to contact me.
https://www.nuget.org/packages/Spire.Office.NETCore/

Sincerely,
Annika
E-iceblue support team
User avatar

Annika.Zhou
 
Posts: 1643
Joined: Wed Apr 07, 2021 2:50 am

Wed Apr 21, 2021 6:07 pm

Hi Annika,

I have successfully installed Spire.Office.NETCore 6.4.2 and PDF images are high resolution.
The problem is solved and case closed.

I want to comment e.iceblue team for your quick response and passionate support, good job!

Best regards,
Alex Sakowski

alexsa248
 
Posts: 4
Joined: Fri Apr 16, 2021 5:13 pm

Thu Apr 22, 2021 10:14 am

Dear Alex,

Thank you for your feedback. I'm glad to hear that your problem has been solved. If there is anything else we can do for you in the future, just feel free to contact us!

Sincerely,
Annika
E-iceblue support team
User avatar

Annika.Zhou
 
Posts: 1643
Joined: Wed Apr 07, 2021 2:50 am

Return to Spire.Presentation