找不到DLL入口点 [英] Can't find DLL entry point
本文介绍了找不到DLL入口点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我一直在尝试在我的VBA项目中调用一个DLL函数,但我不断收到这个错误信息:
I have been trying to call a DLL function in my VBA project but I keep getting this error message:
运行时错误' 453':在Power.dll中找不到DLL入口点CheckStatus
C ++档案:
#define CLASS_DECLSPEC externC__declspec(dllexport)
CLASS_DECLSPEC int __stdcall CheckStatus();
这里是我的尝试在VBA中声明它并调用它:
And here is how I'm trying to declare it and call it in VBA:
Public Declare Function CheckStatus Lib "Power.DLL" () As Long
Dim test As Long
test = CheckStatus
它收到上述错误消息。
有人知道如何解决这个问题吗?感谢。
Does anyone know how to fix this? Thanks.
推荐答案
using this MSDN article, I would try this method of declaring the function:
Public Declare Function CheckStatus Lib "Power.DLL" Alias "_CheckStatus@0" () As Long
这篇关于找不到DLL入口点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文