2

I'm trying to add reference of .net 4.5 class library project to .net core 2.1 project.There are no compile time errors but at the run time it shows FileNotFoundException: Could not load file or assembly 'System.Data.Linq'. I have used System.Data.Linq inside the .net 4.5 project.

Oshada Ekanayake
  • 360
  • 1
  • 2
  • 12
  • 2
    .NET Core can't *reliably* consume .NET Framework libraries (if at all); you really want a .NET Standard or .NET Core library (you should prefer .NET Standard by default) – Marc Gravell Oct 19 '18 at 02:50
  • Possible duplicate of [referencing .NET framework 4 dll in .NET core 2.0](https://stackoverflow.com/questions/52703060/referencing-net-framework-4-dll-in-net-core-2-0) – nvoigt Oct 19 '18 at 11:41
  • 1
    It's not about versions, so whether it's Framework 4.0 or 4.5 and Core 2.0 or 2.1 is irrelevant. – nvoigt Oct 19 '18 at 11:41
  • @MarcGravell Noted & thanks – Oshada Ekanayake Dec 20 '18 at 14:10

0 Answers0