Discussion:
VB.Net + TAPI3: Problems with calling and phone event
(too old to reply)
Steven
2013-06-13 11:08:47 UTC
Permalink
Hello,

using VB.Net and TAPI3 I made an application which should notice incoming calls, display the phone's display content and call a phone number. This application uses a phone which is connected via USB to the computer.

Although TAPI is not supported by managed code, I succeeded in programming nearly all functions. The application can notice incoming calls and it's possible to call a number, but there are still some problems:

- When I pick up the phone's receiver and then call a number in the application, there appears an exception while trying to connect: HRESULT: 0x80040052.

- The application reacts only to the events callnotification, callstate, callinfochange and callhub. The events phoneevent, digitevent, generateevent, gatherdigits and request seem to be ignored by my application.

- According to that: I found nothing detailled about these events: When does the phone or digit event occur?

I use Windows 7 x86 and Visual Basic 2010 to develop the application. Regarding these problems, I researched on the internet and found almost everything you can find about TAPI and .Net, but I found no solution yet. I also tried already the dll from JulMar (ITAPI3), but Visual Basic Express refuses to import.

It would be great if you can help me solving these problems.

Yours faithfully,
Steven
W***@web.de
2013-06-20 08:28:34 UTC
Permalink
Update: Now my application can also notify phone events. I just had to create a phone object by choosing one out of the Address-Phone-Array.

But the first problem is still unsolved:
If the user picks up the phone's receiver before clicking "Dial" in my application, an exception will be throwed. The Code is 0x80040052 and means that there is a certain resource not available (TAPI_RESOUCEUNAVAIL).

The function just does the following while click on the button:
oCall = oAddress.CreateCall(pDestNumber,1,8)
oCall.Connect(false) --> Exception 0x80040052

In another step I tried to unregister the event listener and to close the phone. Then this exception does not occur, but sometimes the connect-Method seems to be in a neverending loop and the application does not react anymore.

Can you help me to solve the problem?
W***@web.de
2013-06-20 10:31:48 UTC
Permalink
Okay, I solved the problem on my own!

Loading...