bad dll calling convention
一个dll文件,我在vc中调用成功
extern "C" __declspec(dllimport) LONG DevOpen ( char* DevName, ULONG FAR * Hdl,ULONG Op, char* ID, SHORT DT, ULONG Rd);
怎么才能在vb中正确调用呢?
我在VB中按下面的声明,调用的时候报错:
run time error:bad dll calling convention
Private Declare Function DevOpen Lib "testapi" (ByVal DevName$, ByVal handle&, Op As Any, ByVal Id$, DT As Any, Rd As Any) As Long
执行到调用
Dim test As Long
Dim ph As Long
test = XSPMOpen("TET", ph, 0, "TT", -1, 0)