Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Fri Sep 14, 2018 10:20 pm

Hi,

I am getting below issue with the latest Spire.Doc version 6.8.16.
Error: A generic error occurred in GDI+.

Can you please provide me your assistance on this issue?

I am getting issue right at below line of code.

document.SaveToStream(memorystream, Spire.Doc.FileFormat.PDF);

Thank you,
Andy

dev.communications
 
Posts: 6
Joined: Wed Sep 05, 2018 2:25 pm

Sat Sep 15, 2018 9:05 pm

More Information :
This issue is not happening on our local machines but this is happening after we deployed our code on Azure server. Please kindly respond on this issue ASAP, if you do not provide us any solution on this then we want move forward and cancel this purchase order. Kindly consider this as high priority.

dev.communications
 
Posts: 6
Joined: Wed Sep 05, 2018 2:25 pm

Mon Sep 17, 2018 1:32 am

Hello,

Thanks for your inquiry and sorry for late reply as weekend.
Please use below code to convert word to PDF on Azure server. If the issue still happens after trying, please provide your word file to help us further investigate your issue. You could send it to us via email (support@e-iceblue.com).
Code: Select all
Document document = new Document();
document.LoadFromFile(wordFile);
ToPdfParameterList tpl = new ToPdfParameterList
{
    UsePSCoversion = true//azure
};
document.SaveToStream(memorystream, tpl);

Sincerely,
Nina
E-iceblue support team
User avatar

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

Mon Sep 17, 2018 2:03 pm

Hi,

I tried below lines of code but still nothing worked out on Azure server, this is working on individual system.

ToPdfParameterList tpl = new ToPdfParameterList
{
UsePSCoversion = true//azure
};
document.SaveToStream(memorystream, tpl);

As requested I can send you word template, please share your email id.

Thanks,
Andy

dev.communications
 
Posts: 6
Joined: Wed Sep 05, 2018 2:25 pm

Tue Sep 18, 2018 1:11 am

Dear Andy,

Please send your word template to Nina.Tang@e-iceblue.com.

Sincerely,
Nina
E-iceblue support team
User avatar

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

Tue Sep 18, 2018 8:39 pm

Hi Nina,

I emailed you the template. Please check and let me know.

Thanks,
Andy

dev.communications
 
Posts: 6
Joined: Wed Sep 05, 2018 2:25 pm

Wed Sep 19, 2018 2:42 am

Hello,

Thanks for your sharing.
I tested your case, but didn’t reproduce your issue. The conversion worked well both on local and Azure. My testing application was attached in email, please deploy it on your Azure and tell us your testing result. I'm looking forward to your reply.

Sincerely,
Nina
E-iceblue support team
User avatar

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

Fri Oct 05, 2018 1:48 pm

I figured this out.
The solution for my problem is to register "Microsoft.SaaS" on "Resource Providers" under my Azure subscription. This resolved the problem. Thank you for your time.

dev.communications
 
Posts: 6
Joined: Wed Sep 05, 2018 2:25 pm

Tue Oct 09, 2018 8:21 am

Hi,

Glad to hear that.
If you need helps in the future, just feel free to contact us.
Wish you all the best!

Sincerely,
Nina
E-iceblue support team
User avatar

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

Return to Spire.Doc