« ROWID in FileMaker SQ… | Home | MBS FileMaker Plugin,… »

Use of TAPI functions in MBS FileMaker Plugin

Last week a client had to implement MBS FileMaker Plugin functions for TAPI (Windows Telephone API) and got some instructions for us:

How to connect a phone system (Mitel MiVoice400) with MBS Plugin to call a phone number with an Astra phone in Windows. With free phoner app, we can list all devices for TAPI including their address name. In the follow picture, you see that "Hanspeter (MiVoice5370)" is the required one.



In your FileMaker script you call MBS( "TAPI.Initialize" ) first to initialize the TAPI functions on startup of your solution. Later you call MBS( "TAPI.AddressCount" ) to query the number of addresses for the computer. For the client's PC, we get back 6 as the count. That is the same as in phoner app above. Now you can step over the connections from 0 to 5 to query name for each. With the call MBS( "TAPI.AddressValue"; 5 ; "AddressName" ) we get back the address name "Hanspeter (MiVoice5370)".

Next we create a call and for this we need two commands:

$call = MBS( "TAPI.CreateCall"; $AddressName ; "0“ & $PhoneNumber ; 1 ; 8).
MBS( "TAPI.Connect"; $call ; 1 )

As the phone system needs prefix 0 for calling outside, we add a "0" as prefix to the phone number. Media type for an audio call is 8 and 1 is passed for address type to be an phone number. For the connect call to actually start the call, we pass 1 for synchronous mode, which seems to work well for this phone system.

In general the TAPI functions work well for all customers and getting the address name and right ID configured can be a challenge.

For Xojo, you can use our MBS Xojo Win Plugin and the TAPIMBS class. Claris FileMaker Plugin
17 12 18 - 08:33