VC中如下定义 extern "C" short APIENTRY SmsSend(int Port,char *MobilePhone, char *Message); 在VB中 Declare Function SmsSend Lib "SmsDll" (ByVal Port As Integer, ByVal MobilePhone As String, ByVal Message As String) As IntegerDim MobilePhone As String * 21 Dim Message As String * 201 Dim Port As Long Ret = SmsSend(Port, MobilePhone,Message) 这是实际使用的程序,肯定没问题
另,是否可以从VB向VC传递数组?
你或者可以用VARIANT啊
extern "C" short APIENTRY SmsSend(int Port,char *MobilePhone, char *Message); 在VB中
Declare Function SmsSend Lib "SmsDll" (ByVal Port As Integer, ByVal MobilePhone As String, ByVal Message As String) As IntegerDim MobilePhone As String * 21
Dim Message As String * 201
Dim Port As Long
Ret = SmsSend(Port, MobilePhone,Message)
这是实际使用的程序,肯定没问题