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.

Wed Jul 31, 2019 4:16 pm

Hello, I tried using the FreeSpire.Doc NUGET to save DOCX and RTF documents as images (jpeg and gif). The first time I did this I didn't have any issues. Then I found out I could have PDFs as input, so I added FreeSpire.PDF NUGET to save a PDF as a DOCX. That worked, but then my FreeSpire.Doc stuff stopped working. This is the error I'm getting:

System.IO.FileLoadException
HResult=0x80131040
Message=Could not load file or assembly 'Spire.Pdf, Version=5.4.15.20046, Culture=neutral, PublicKeyToken=663f351905198cb3' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
Source=Spire.Doc
StackTrace:
at Spire.Doc.Document.ᜍ()
at Spire.Doc.Document..ctor()
at MessageConverter.worker.InterrogateWord(String FileWithPath) in C:\development\MessageConverter\MessageConverter\worker.cs:line 36
at MessageConverter.Program.Main(String[] args) in C:\development\MessageConverter\MessageConverter\Program.cs:line 21

Inner Exception 1:
FileLoadException: Could not load file or assembly 'Spire.Pdf, Version=5.2.17.19040, Culture=neutral, PublicKeyToken=663f351905198cb3' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)


So I removed the FreeSpire.PDF NUGET and I still get the error. I've tried removing the FreeSpire.Doc nuget and adding the FreeSpire.Office NUGET and I get the same error.

Can two different FreeSpire NUGETS exist in the same solution? Is this a *FreeSpire* only issue or would I have the same issue if I got approval to purchase a non free version?

DanRoche
 
Posts: 3
Joined: Mon Jul 29, 2019 4:14 pm

Thu Aug 01, 2019 2:45 am

Hi,

Thanks for your inquiry.
Free Spire.Doc and Free Spire.PDF cannot be installed in same project. Please uninstall all Spire product firstly then clear and build your project, finally only install free Spire.Office which includes all our product in your project.
If there is any question, welcome to get it back to us.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Fri Aug 02, 2019 12:50 am

Thanks - must be the one thing I didn't do after uninstalling (clean and build) but I still got the error. There was a runtime section in the app.config I had to delete to get passed that error.

DanRoche
 
Posts: 3
Joined: Mon Jul 29, 2019 4:14 pm

Fri Aug 02, 2019 1:50 am

Hi,

Glad to hear your issue is solved.
If there is any question while using our product, just feel free to contact us.
Have a nice day!

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy.jiang
 
Posts: 3099
Joined: Tue Sep 06, 2016 8:30 am

Return to Spire.Doc