c# - NuGet AzureServiceBus 问题

标签 c# visual-studio azure win-universal-app servicebus

我正在使用 Azure 开展 IoT 项目。我的目的是在向 iotHub 上传数据时检查从 iotHub 发送的“反馈”消息。

为此,我尝试安装 WindowsAzure.ServiceBus(版本 5.0,但甚至尝试了以前的版本)NuGet 包。我遇到了这些类型的错误:

    Il pacchetto System.IdentityModel.Tokens.Jwt 4.0.4.403061554 non è compatibile con uap10.0.14393 (UAP,Version=v10.0.14393). Il pacchetto System.IdentityModel.Tokens.Jwt 4.0.4.403061554 supporta: net45 (.NETFramework,Version=v4.5)

Il pacchetto WindowsAzure.ServiceBus 5.0.0 non è compatibile con uap10.0.14393 (UAP,Version=v10.0.14393)/win10-arm-aot. Il pacchetto WindowsAzure.ServiceBus 5.0.0 supporta: net46 (.NETFramework,Version=v4.6)

对于不是意大利语的人,它会显示“数据包 xxx 与 xxx 不兼容”。

于是我在网上搜索并找到了一些“解决方案”:

1) 清除 NuGet 缓存并重新下载。完成后,问题仍然存在。

2) 手动安装 .NET Framework 4.6 和 4.5 。对于 4.6,成功完成,但 4.5 不可用...所以问题也没有解决(更糟糕的是它无法识别我的 .NET Framework 4.6)。

所以我尝试更深入地搜索,我更改了构建我的 UWP 项目的 Windows 10 的最低版本,但没有任何更改...所以这就是我向您寻求帮助的原因。

非常感谢!

PS:我的.NET Framework,各种更新都成功完成,我就是无法安装这个包...VS Studio 2017

最佳答案

WindowsAzure.ServiceBus 是 .Net Framework 应用程序的包。

有一个类似的.Net Standard包Microsoft.Azure.ServiceBus适用于 .Net Framework、.Net Standard 和 .Net Core 应用程序。

根据您的项目类型,您可以在这些包之间进行选择。

关于c# - NuGet AzureServiceBus 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51669494/

相关文章:

c# - 具有构建操作的 VSTemplate

c++ - DirectX 11 调试层捕获错误字符串

c# - Azure Storage Queue.AddMessageAsync(item,cancelToken) 缺少接受两个参数的方法

c# - "The specified package is invalid. The main part is missing."在封闭的 XML 中

c# - 在代码中设置 Far Future Expires header - ASP.NET

c# - 我可以使用查询设计器针对数据集编写 Linq 查询吗

c++ - fatal error LNK1169 : one or more multiply defined symbols found (C++)

c# - Visual Studio 2013 中的 FxCop 和代码分析

c# - Azure CDN 端点使用 https 提供 502 错误网关

azure - 通过代理连接到 Azure 服务总线 - Java