Hi people
I've searched the web all over looking for how to call a C++ API function from VB.Net. I know you must use marshalling, but I'm really struggling on this one because of the structures being used. I'm looking at upgrading my app to VB.Net from VB6 but this is the only thing stopping me. Here is the way I called the API from VB6:
Public Type gtRpcError
StatusClass As Integer
StatusEppix As Long
MessageData As String * 51
StatusValue As Long
IsamValue As Integer
ErrorText As String * 501
End Type
Public Type gtRpcActionManagerUserGet
userName As String * 33
NodeID As String * 41
NodeLevel As Integer
Superior As String * 21
StaffCount As Long
TrgGroupCount As Long
TrgSuperCount As Long
End Type
Declare Function CFGL_ActionManagerUser_Get Lib "cst_32C" ( _
ByVal LoginID As String, _
ByRef gtRpcActionManagerUserGet As gtRpcActionManagerUserGet) As gtRpcError
If anyone can please help, I would deeply appreciate it!!
Thank you and regards,
Jean Pierre