Using Spire.doc, Spire.xls and Spire.Presentation in same project

0

Is it possible to use the 3 products in the same project?

Just downloaded the free versions of each and the Spire.PDF.dll version are different and causes error "System.IO.FileLoadException: Could not load file or assembly 'Spire.Pdf, Version=3.0.10.54040, 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)"

Spire.doc uses version 3.0.10.54040 and Spire.Presentation uses 3.0.49.58040

I tried using dependentAssembly

  <dependentAssembly>
    <assemblyIdentity name="Spire.Pdf" publicKeyToken="663f351905198cb3" culture="neutral" />
    <bindingRedirect oldVersion="0.0.0.0-3.0.10.54040" newVersion="3.0.49.58040" />
  </dependentAssembly>

But get an error

TypeLoadException: Could not load type 'sprẒ' from assembly 'Spire.Pdf,
Version=3.0.49.58040, Culture=neutral, PublicKeyToken=663f351905198cb3'.
c#
asp.net-mvc
spire
asked on Stack Overflow Jul 7, 2014 by Eduardo Molteni • edited Dec 21, 2015 by Eduardo Molteni

2 Answers

0

Alone three libraries can't be used in the same project. You can download the free Spire.Office which including libraries of Spire.Doc, Spire XLS, Spire.Presentation, Spire.PDF, Spire.DataExport, Spire.PDFViewer, Spire.DocViewer and so on. Using Spire.Office you can use libraries of Spire.Doc,Spire.Presention and Spire.Xls in same project.

0

Clear out the 'dependentAssembly' section that references the Spire Dlls in your 'app.config' file altogether. That's what worked for me.

answered on Stack Overflow Jan 22, 2020 by ecklerpa

User contributions licensed under CC BY-SA 3.0