Tapi

I am new to Tapi in VB6 , I have a tapi
sdk installed, I am trying to translate some of the functions from the C++ documentaion to VB I am running into a problem with lineInitializeEx.

I am declaring it like this

Private Declare Function lineInitializeEx Lib "TAPI32.DLL" Alias "lineInitializeExA" (ByVal lphLineApp _
                    As String, ByVal hInstance As String, ByVal lpfnCallBack As String, _
                    ByVal lpszFriendlyAppName As String, ByVal lpdwNumDevs As String, _
                    ByVal lpdwAPIVersion As String, ByVal LINEINITIALIZEEXPARAMS) As Long


but every time I call it I get this error:

Only public user defined types defined in public object modules can be used as parameters or return types for public procedures of class modules or as fields of public user defined types


Help any body  
madarabAsked:
Who is Participating?
 
raymerConnect With a Mentor Commented:
See my complete TAPI 2.1 example at Shrinkwrap Visual Basic for how to use LineInitializeEx from VB.

Hope this helps,
Ray Mercer
MS-MVP Visual Basic
http://www.shrinkwrapvb.com
0
 
mcriderCommented:
In your DECLARE line, you have:


   ..., ByVal LINEINITIALIZEEXPARAMS) As Long

Don't you need to do something like this:

   ..., ByVal linit As LINEINITIALIZEEXPARAMS) As Long


Also, LINEINITIALIZEEXPARAMS should be a PUBLIC TYPE definition...


Cheers!
0
All Courses

From novice to tech pro — start learning today.