DLL Function

Post Reply
Peterg
Posts: 62
Joined: Mon Nov 28, 2005 5:36 pm
Location: Oxford UK
Contact:

DLL Function

Post by Peterg »

Hi all
I am trying to use an external dll which gives an example in vb as
Declare Function ZcSearchString(ByVal conn As Long, _
ByVal SrchType As Integer, _
ByVal Columns As String, _
ByVal ColDelim As String, _
ByVal Query As String, _
ByVal Timeout As Integer, _
ByVal ShowList As Integer) _
As String


I have tried to change this to
DLL32 Function ZcSearchString (Mconn As LONG, SrchType As BYTE, Columns As LPSTR, ColDelim As LPSTR, Query As LPSTR, Timeout As BYTE, ShowList As BYTE) As STRING PASCAL LIB "ZCVBCLNT.DLL"

but it does not work. Can anyone help

Peter
User avatar
Enrico Maria Giordano
Posts: 7356
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia
Contact:

Re: DLL Function

Post by Enrico Maria Giordano »

Try

DLL32 Function ZcSearchString (Mconn As LONG, SrchType As LONG, Columns As LPSTR, ColDelim As LPSTR, Query As LPSTR, Timeout As LONG, ShowList As LONG) As LPSTR PASCAL LIB "ZCVBCLNT.DLL"

EMG
Peterg
Posts: 62
Joined: Mon Nov 28, 2005 5:36 pm
Location: Oxford UK
Contact:

Post by Peterg »

Thanks got it working by playing with String and LTSTR. Thanks

BTW DLL Function works but DLL32 does not

Peter
Post Reply