.net core classlibrary calling .net framework class library

后端 未结 2 1859
再見小時候
再見小時候 2021-01-14 02:34

Could not find an answer to my doubts and hopefully somebody can clarify.

I Have created a dummy solution with

  • 1 class library(.net framework)
  • <
2条回答
  •  再見小時候
    2021-01-14 02:51

    You could try to use a shared library project. It compiles against the platform of the referencing application/library, so to speak. That gives you the ability to create class libraries targeting different platforms without the need to duplicate any code, but it may require some #if...

    https://blogs.msdn.microsoft.com/dotnet/2014/04/21/sharing-code-across-platforms/

提交回复
热议问题