简体   繁体   English

如何在.NET Core 2.1项目中引用/导入.NET Standard 2.0类型?

[英]How do you reference/import .NET Standard 2.0 types in a .NET Core 2.1 project?

I have a .NET standard 2.0 class library that i keep all my domain classes in (just POCOs no dependencies). 我有一个.NET标准2.0类库,我将所有域类都保留在其中(只是POCO没有依赖性)。

I have a .NET core 2.1 azure functions project also. 我也有一个.NET core 2.1天蓝色功能项目。 In visual studio i added a project reference to the class library, but it doesn't recognize any of my namespaces and classes when I try to reference them. 在Visual Studio中,我向类库添加了项目引用,但是当我尝试引用它们时,它无法识别我的任何名称空间和类。

I just created an azure function , I see nowhere .Net Core 2.1 , currently there are two versions a V1 in .Net Framework and V2 .Net Standard as you can see on the screenshot below, otherwise I find this link that you might be interested in, there are people who have the same problem as you, and they recommend to update to .Net Core 2.2 . 我刚刚创建了一个azure函数 ,我看不到.Net Core 2.1 ,目前在.Net Framework和V2 .Net Standard中有两个版本,如下面的屏幕截图所示,否则,我可能会对此链接感兴趣,有些人和您有同样的问题,因此建议您更新到.Net Core 2.2

The link below: 下面的链接:

https://github.com/Azure/azure-functions-templates/issues/829 https://github.com/Azure/azure-functions-templates/issues/829

在此处输入图片说明

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何从 a.Net 标准 2.0 添加对 a.Net Core 3.1 项目的引用? - How to add a reference to a .Net Core 3.1 project from a .Net standard 2.0? 在.Net标准2.0项目中添加dll参考 - Adding dll reference in .Net standard 2.0 project 问题:在.Net Core 3.1 中引用.Net Standard 2.1 项目 - Issue: Referring .Net Standard 2.1 project in .Net Core 3.1 如何在 .NET Standard 2.0/Core 2.1 中使用 PrivateKey 创建 X509Certificate2? - How to create X509Certificate2 with PrivateKey in .NET Standard 2.0/Core 2.1? 如何在基于 .NET Framework 4.6.1 构建的单元测试项目中添加 .NET Core 2.1 项目引用 - How to add .NET Core 2.1 project reference in Unit Test project built on .NET Framework 4.6.1 标准Windows窗体参考.NET Core项目 - Standard Windows Forms reference .NET Core project .Net Core 2.0 与.Net Core 2.1 兼容 - .Net Core 2.0 compatible with .Net Core 2.1 如何在 .NET Core 项目中引用 .NET Framework 项目? - How do I reference a .NET Framework project in a .NET Core project? 如何在新创建的.NET Core 2.0 Web应用程序中定位.NET Standard 2.0? - How do I target .NET Standard 2.0 in a freshly created .NET Core 2.0 web app? 在 .NET Core 2.1 项目中添加对 Java.Util 的引用 - Adding reference to Java.Util in .NET Core 2.1 project
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM