【发布时间】:2021-07-27 17:09:19
【问题描述】:
代码在Windows 10 上运行良好,
但是在我的.NET 5 winforms 应用程序中使用 uwp 蓝牙 API 时,我在Windows 8.1 中得到了TargetInvocationException
内部异常是
Class not registered (0x80040154 (REGDB_E_CLASSNOTREG))
代码:
private BluetoothLEAdvertisementWatcher BTWatch = new BluetoothLEAdvertisementWatcher();
在我的项目中,我添加了对“UwpDesktop-Updated”包的引用,并且我的 Windows 8.1 机器上安装了 windows SDK 10.0.17763.132。
让我知道如何解决在 Windows 8.1 上出现的这个问题
【问题讨论】: