"Integrate WSDK into Application"教程 DJI-SDK 中的问题



我按照本教程 https://developer.dji.com/windows-sdk/documentation/application-development-workflow/workflow-integrate.html

我有这个错误:

Severity    Code    Description Project File    Line    Suppression State
Error   CS7069  Reference to type 'Task<>' claims it is defined in 'System.Runtime', but it could not be found DJIWSDKDemo C:Usersalmendro.avellanosourcereposDJIWSDKDemoDJIWSDKDemoMainPage.xaml.cs 61  Active

如果我注释该行并运行它,请向我显示下一个错误:

System.Reflection.TargetInvocationException
HResult=0x80131604
Message=Exception has been thrown by the target of an invocation.
Source=
StackTrace:
Inner Exception 1:
FileLoadException: Could not load file or assembly 'System.Runtime, Version=4.2.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The located assembly's manifest definition does not match the assembly reference. Exception from HRESULT: 0x80131040

我正在使用VS 2019。感谢您的帮助

VS2017 在行的相同问题:

var productType = (await DJISDKManager.Instance.ComponentManager.GetProductHandler(0).GetProductTypeAsync()).value;

除了错误之外,还有 11 个警告与 System.Threading, System.Runtime 版本之间的冲突有关,等等。

可能是 VS 或通用 Windows 引用的问题。

最新更新