Delphi调用VC++的动态库问题
/****************************************************************************** * Function: HV_OpenDevice * Description: 打开设备 * Format: * HRESULT HV_OpenDevice(int nDevId) ; * Params: * int nId: 设备索引 * Return: * HV_SUCCESS: 成功; HV_NO_SUCH_DEVICE: 未找到 ******************************************************************************/HVGIGE_WP_API HRESULT __stdcall HV_OpenDevice(int nDevId);
function HV_OpenDevice(nDevId: Integer):Integer;stdcall;external 'HVGigE_WP.dll' name 'HV_
运行的时候直接就弹出提示:
无法定位程序输入点 HV_OpenDevice 于动态链接库 'HVGigE_WP.dll' 上
有的c++编译器会自动在实际编译出的函数名前面加下划线。
可以depends攻击看一下那个dll实际输出的函数名是什么
dll版本不是最新的,找厂商要拿最新的
是
function HV_OpenDevice(nDevId: Integer):Integer;stdcall;external 'HVGigE_WP.dll' name 'HV_OpenDevice@@YGJH@Z';