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 Jan 30, 2015 2:15 pm

I'm getting the following error when I try to use New Document(filepath):
The type initializer for 'sprᨘ' threw an exception.


What is causing it and how do I fix it?

Hampo
 
Posts: 28
Joined: Thu Jan 22, 2015 2:29 pm

Mon Feb 02, 2015 3:52 am

Hello Hampo,

Thanks for your inquiry.

Try to clean the solution and rebuild it. If this problem still happens, please provide us more information like your code snippet, sample docuemnt, testing project, etc.

Thank you.
Best Regards,
Burning
E-iceblue Support Team
User avatar

burning.liu
 
Posts: 406
Joined: Mon Aug 04, 2014 6:47 am

Wed Feb 04, 2015 9:27 am

This error only occurs when the project is run in x86, which is required.

Unfortunately I can not post the project on here.

Hampo
 
Posts: 28
Joined: Thu Jan 22, 2015 2:29 pm

Thu Feb 05, 2015 6:48 am

Hello Hampo,

Not the whole project you designed, just a simple project which would cause this problem. The information you provided so far is very little so that we cannot reproduce this problem, it would be better if you can give us more, thank you.
Best Regards,
Burning
E-iceblue Support Team
User avatar

burning.liu
 
Posts: 406
Joined: Mon Aug 04, 2014 6:47 am

Mon Feb 09, 2015 3:36 pm

This was solved by including Spire.Pdf.Dll in the same directory as the other requirements.

Hampo
 
Posts: 28
Joined: Thu Jan 22, 2015 2:29 pm

Tue Feb 10, 2015 1:03 am

Hello,

Glad to hear that this problem has been solved.

Please feel free to contact us if you have any questions.
Best Regards,
Burning
E-iceblue Support Team
User avatar

burning.liu
 
Posts: 406
Joined: Mon Aug 04, 2014 6:47 am

Thu Feb 26, 2015 9:00 pm

"The type initializer for 'sprᨘ' threw an exception."
I'm getting this error.

Tried cleaning the solution and rebuilding it. I'll build a solution example soon. Thanks.

jtenner
 
Posts: 1
Joined: Thu May 22, 2014 3:26 pm

Fri Feb 27, 2015 6:23 am

Dear jtenner,

Please feel free to contact us if you have any questions.
Best Regards,
Burning
E-iceblue Support Team
User avatar

burning.liu
 
Posts: 406
Joined: Mon Aug 04, 2014 6:47 am

Return to Spire.Doc