c# - Xamarin Forms 链接的 DLL 异常
问题描述
我在尝试将 DLL 文件链接到我的 Xamarin Forms 项目时遇到问题。我按照这里的建议添加 DLL 文件作为对项目 Android 部分的引用。我还尝试将引用链接添加到 DLL 文件随附的 C# 文件中。我不太确定这个异常是什么,尤其是如何解决它。任何帮助将不胜感激。仅供参考,下面的代码仅用于 Android 项目的 MainActivity.cs 文件,而不是普通的 Xamarin.Forms 文件。但是我在那里遇到了同样的错误。
使用的代码:
UInt32 ftdiDeviceCount = 0;
var newDevice = new FTDI();
FTDI.FT_STATUS ftStatus = newDevice.GetNumberOfDevices(ref ftdiDeviceCount);
例外:
**System.EntryPointNotFoundException:** 'LoadLibrary assembly:<unknown assembly> type:<unknown type> member:(null)'
解决方案
推荐阅读
- reactjs - 反应应用程序的登录身份验证
- swift - 在钥匙串 Swift 中存储整数
- c++ - (c ++ 23隐式移动)将移动的本地存储变量作为右值引用返回,只有括号?
- android - EPSON 蓝牙打印机 TM-P60II 中的阿拉伯字符反向打印
- unit-testing - 无法在 mockito 中模拟方法
- wordpress - 为按钮添加链接
- python - 我正在构建一个 fastapi 应用程序错误“无法从 python 元组类型确定数据库类型”
- javascript - 如何通过单击按钮获得多个 vue-multiselect 实例
- javascript - How to show area chart with timeseries configuration with different datasets in Chart.js v3?
- android - 我有一个折叠工具栏和嵌套滚动视图,我不能让它工作