Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

tapi - how to ?

72 views
Skip to first unread message

Michael Hagl

unread,
Oct 11, 2010, 9:22:14 AM10/11/10
to
Hi,

does anybody knows how to dial a phone number using tapi ?

Thank you

Michael Hagl

dlzc

unread,
Oct 11, 2010, 10:08:40 AM10/11/10
to
Dear Michael Hagl:

On Oct 11, 6:22 am, "Michael Hagl" <hag...@hagl.de> wrote:
> Hi,
>
> does anybody knows how to dial a phone number
> using tapi ?

Still not much of an answer to your need\:
http://groups.google.com/group/comp.lang.xharbour/msg/1fc43b9d37f58687

This might be more help:
http://msdn.microsoft.com/en-us/library/ms734257(VS.85).aspx

David A. Smith

Michael Hagl

unread,
Oct 12, 2010, 7:12:21 AM10/12/10
to
Thank you for the link, but I know this MS-Site and at the moment it does
not help much, because I have no C skills.

Michael.

"dlzc" <dl...@cox.net> schrieb im Newsbeitrag
news:3884453a-deed-4557...@z30g2000prg.googlegroups.com...

Michael Hagl

unread,
Oct 13, 2010, 2:44:37 AM10/13/10
to
Hi,

I had a look at Pritpal Bedi's vouch32 activeX server. And it's tapi server
is able to dial a phone number.

But it seems there is no development since 4 years. When registerung the
dll, there is an error message:

"Module Vouche32x.prg was compiled into PCODE version: 7, this version of
xHarbour expects version: 10"

I feel not very comfortable, when using a third party product without source
code and without ongoing development.


Michael Hagl

"dlzc" <dl...@cox.net> schrieb im Newsbeitrag
news:3884453a-deed-4557...@z30g2000prg.googlegroups.com...

pcordo

unread,
Oct 13, 2010, 2:54:23 AM10/13/10
to
On 13 Oct, 08:44, "Michael Hagl" <hag...@hagl.de> wrote:
> Hi,
>
> I had a look at Pritpal Bedi's vouch32 activeX server. And it's tapi server
> is able to dial a phone number.
>
> But it seems there is no development since 4 years. When registerung the
> dll, there is an error message:
>
> "Module Vouche32x.prg was compiled into PCODE version: 7, this version of
> xHarbour expects version: 10"
>
> I feel not very comfortable, when using a third party product without source
> code and without ongoing development.
>
> Michael Hagl
>
> "dlzc" <dl...@cox.net> schrieb im Newsbeitragnews:3884453a-deed-4557...@z30g2000prg.googlegroups.com...

> Dear Michael Hagl:
>
> On Oct 11, 6:22 am, "Michael Hagl" <hag...@hagl.de> wrote:
>
> > Hi,
>
> > does anybody knows how to dial a phone number
> > using tapi ?
>
> Still not much of an answer to your need\:http://groups.google.com/group/comp.lang.xharbour/msg/1fc43b9d37f58687
>
> This might be more help:http://msdn.microsoft.com/en-us/library/ms734257(VS.85).aspx
>
> David A. Smith

Hi Michael Hagl, you can use this code:


// Creem la Trucada.
hLib:= DllLoad("TAPI32.DLL")
hCall:= DllCall(hLib,0x0020,"tapiRequestMakeCall",cPhone, "", "",
"")
Freelibrary(hLib)

Pere Cordonet

Michael Hagl

unread,
Oct 13, 2010, 3:16:29 AM10/13/10
to
Thank you Pere,

your code works !! My prog dials a phone number

I will try to investigate the TapiRequestMakeCall function and test how it
works on different systems with different tapi's, because the function
should work on all customers systems with all the tapi they have.

Thank you

Michael Hagl

"pcordo" <pereco...@gmail.com> schrieb im Newsbeitrag
news:ddca9632-d18d-42c4...@x23g2000vba.googlegroups.com...

Michael Hagl

unread,
Oct 15, 2010, 3:47:55 AM10/15/10
to
Hi to all,

dialing a phone number works with the following code (Thanks to Pere
Cordonet). This is using the windows dialer.exe. I' searching for sourcecode
sample to use tapi without the diealer.exe.

#DEFINE TAPIERR_CONNECTED 0
#DEFINE TAPIERR_DROPPED -1
#DEFINE TAPIERR_NOREQUESTRECIPIENT -2
#DEFINE TAPIERR_REQUESTQUEUEFULL -3
#DEFINE TAPIERR_INVALDESTADDRESS -4
#DEFINE TAPIERR_INVALWINDOWHANDLE -5
#DEFINE TAPIERR_INVALDEVICECLASS -6
#DEFINE TAPIERR_INVALDEVICEID -7
#DEFINE TAPIERR_DEVICECLASSUNAVAIL -8
#DEFINE TAPIERR_DEVICEIDUNAVAIL -9
#DEFINE TAPIERR_DEVICEINUSE -10
#DEFINE TAPIERR_DESTBUSY -11
#DEFINE TAPIERR_DESTNOANSWER -12
#DEFINE TAPIERR_DESTUNAVAIL -13
#DEFINE TAPIERR_UNKNOWNWINHANDLE -14
#DEFINE TAPIERR_UNKNOWNREQUESTID -15
#DEFINE TAPIERR_REQUESTFAILED -16
#DEFINE TAPIERR_REQUESTCANCELLED -17
#DEFINE TAPIERR_INVALPOINTER -18


FUNCTION TapiCall(cNr)
LOCAL hLib, nCall

hLib:= DllLoad("TAPI32.DLL")

nCall:= DllCall(hLib,0x0020,"tapiRequestMakeCall",cNr, "", "","")
Freelibrary(hLib)
IF nCall = TAPIERR_NOREQUESTRECIPIENT
Getwait("Anrufmanager nicht erreichbar !!")
ELSEIF nCall = TAPIERR_REQUESTQUEUEFULL
Getwait("Anwahlwarteschlage voll !!")
ELSEIF nCall = TAPIERR_INVALDESTADDRESS
Getwait("Ung�ltige Telefonnummer !!")
ELSEIF nCall <> 0
Getwait("Anwahl nicht m�glich (Fehler: "+Strtrim(nCall)+")")
ENDIF
RETURN NIL


Michael Hagl


0 new messages