> Anyone has any experience using TAPI 3 in Visual Foxpro? I am trying to get the callerid data from a modem when there is an incoming call.
>
> I already managed to do it "old school" with the mscomm control, but if I could do it using TAPI it would be great.
>
> I have not found that much info about FoxPro and TAPI 3. I tried opening the Microsoft TAPI 3.0 type library in the object browser, I drag and drop the ITTAPI interface to a prg, and get:
>
>
x=NEWOBJECT("myclass")
>
> DEFINE CLASS myclass AS session OLEPUBLIC
>
> IMPLEMENTS ITTAPI IN "TAPI3Lib.TAPI"
> ...
>
>
> But when I run this I get "Type Library TAPI3Lib.TAPI not found"
>
> The problem is:
>
> I don't know anything about TAPI, COM, iDispatch, iUnknown, etc, etc, so I guess I have no hope of making this work right?
>
> Is there any info, docs, faq, howto I could read about this that is not like reading ancient egyptian jeroglifics?
>
> Deep down I suspect the whole COM business is an indescifrable mess, but maybe it´s just me.
>
> ---
> Carlos Alloatti
I also know nothing about TAPI but maybe you need this:
x=NEWOBJECT("myclass")
DEFINE CLASS myclass AS session OLEPUBLIC
IMPLEMENTS ITCallInfo2 IN "c:\windows\system32\tapi3.dll"
PROCEDURE ITCallInfo2_get_Address() AS VARIANT;
HELPSTRING "property Address"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_CallState() AS VARIANT;
HELPSTRING "property CallState"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_Privilege() AS VARIANT;
HELPSTRING "property Privilege"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_CallHub() AS VARIANT;
HELPSTRING "property CallHub"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_CallInfoLong(CallInfoLong AS VARIANT) AS Number;
HELPSTRING "property CallInfoLong"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_put_CallInfoLong(CallInfoLong AS VARIANT, eValue AS Number @);
HELPSTRING "property CallInfoLong"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_CallInfoString(CallInfoString AS VARIANT) AS STRING;
HELPSTRING "property CallInfoString"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_put_CallInfoString(CallInfoString AS VARIANT,eValue AS STRING @);
HELPSTRING "property CallInfoString"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_CallInfoBuffer(CallInfoBuffer AS VARIANT) AS VARIANT;
HELPSTRING "property CallInfoBuffer"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_put_CallInfoBuffer(CallInfoBuffer AS VARIANT, eValue AS VARIANT @);
HELPSTRING "property CallInfoBuffer"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_GetCallInfoBuffer(CallInfoBuffer AS VARIANT, pdwSize AS NUMBER, ppCallInfoBuffer AS NUMBER) AS VOID
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_SetCallInfoBuffer(CallInfoBuffer AS VARIANT, dwSize AS NUMBER, pCallInfoBuffer AS NUMBER) AS VOID
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_ReleaseUserUserInfo() AS VOID;
HELPSTRING "method ReleaseUserUserInfo"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_get_EventFilter(TapiEvent AS VARIANT, lSubEvent AS Number) AS LOGICAL;
HELPSTRING "method EventFilter"
* add user code here
ENDPROC
PROCEDURE ITCallInfo2_put_EventFilter(TapiEvent AS VARIANT, lSubEvent AS Number,eValue AS LOGICAL @);
HELPSTRING "method EventFilter"
* add user code here
ENDPROC
ENDDEFINE
-----------------
Borislav Borissov
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von SchillerThe only thing normal about database guys is their tables.