I'm attempting to use Net Core in my mvc application for security policies. Articles I've read said I need to install DependencyInjection which I'm doing through NuGet in VS 2017. I'm getting the following error:
Could not install package 'Microsoft.Extensions.DependencyInjection.Abstractions 2.0.0'. 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.
Is this version too new for .net 4.5.2? What version should I be using?
If you check the dependencies you can see it depends on NetStandard 2.0. From this chart you can see that you must be using at .net 4.6.1 to be compatible with NetStandard 2.0.
If you use Microsoft.Extensions.DependencyInjection.Abstractions 1.1.1 that is compatible .NETStandard 1.0 which is compatible with .NET 4.5 or newer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With