Problem installing new Nuget Pack

Asked

Viewed 933 times

0

I try to download PDF.js via Nuget, but it is a problem:

Error: Could not install package 'PDF.js 1.3.91'. You are trying to install this package into a project that targets '.NETFramework,Version=v4.5.2', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.

I’m using Visual Studio of the year 2015.

Someone has been through it ? And how to solve ?

1 answer

0

This occurs when the version of . NET Framework on which the Nuget package was compiled is different from the version of the project in which one is trying to install.

The bigger problem is that the owner of the Nuget package did not specify which version of . NET Framework the Nuget package depends on. And we ended up getting this super awkward error.

In the case of this particular package, to make matters worse, the link to the project’s website is fake. So we can’t even go to the official componentar website to check the compiled version.

What you can do to try to run is to change the version of . NET Framrwork that will compile your project, until you find one that works.

On the Nuget package website there is a "Contact Owners" link. You can also send them a message asking for the version and asking them to add the version of . NET Framework as dependency.

  • Hi @Thiago Lunardi, I risk changing the version of NET Framrwork ?

  • If you want to use the PDF.js package, yes. Have a change, as it does not support the v4.5.2 version.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.