我有一个VBA项目,可以将3个调用进入第三方dll,如下所示:
Private Declare Function cm_checkprotection Lib "ACPPYRAMID.DLL" Alias "CM_CheckProtection" (ByVal options As Long) As Long
Private Declare Function cm_getextendederror Lib "ACPPYRAMID.DLL" Alias "CM_GetExtendedError" (ByVal ExtErr As Any) As Long
Private Declare Function cm_getproductkeya Lib "ACPPYRAMID.DLL" Alias "CM_GetProductKeyA" (ByVal ProductKey As Any) As Long
我正在尝试将此项目移植到64位Excel中,但是当我在声明中添加“PtrSafe”时,Excel barfs会出现“Expected:Expression”错误,如附图所示。
知道如何解决这个问题吗?
TIA,
坦率
将位置转移到
Private Declare PtrSafe Function