|
Hi Bishoy,
I am working mobile application, which will block call. I have code to block outgoing call but it is having one ring delay.
can we write code to block outgoing call without any notification and one ring delay.
Thanks in advance.
I am prashant working with Aurasoft Technologies solution Pvt. Ltd.
Prashant.
|
|
|
|
|
MediaModem is defined as a constant with a value of 16
this test asks: "if MediaModem =MediaModem "
surely that can't be right.
I'm new to this, but I can't see how it can be right. I'm suck can anybody shed light on it for me?
<br />
<br />
Thanks<br />
<br />
<br />
Ed
|
|
|
|
|
Hi Ed,
propably you've used something like this before its called Bitwise And operation and this statement is two parts to understand here
first "(MediaTypes And MediaModem)" and this will result 0 if MediTypes does not contain the value of MediaModem, otherwise it will return the value of MediaModem
and the second part is "If (MediaTypes And MediaModem) = MediaModem Then"
which will use the outcome of the first bitwise operation and compare it to the value of MediaModem and in this case it will succeed only if the result of the bitwise And operation yielded the Value of MediaModem.
and this is because MediaTypes variable contains multiple values combined together with Bitwise Oring, we must use Anding to check if one if the values exist or not.
"Imagination is more important than knowledge.."
{Albert Einstein}
|
|
|
|
|
|
I have downloaded the source code, created a form and created a new VBTAPI in the form, now how do i work with the events.
Thanks
|
|
|
|
|
Hi Everyone,
I was struggling to develope a TAPI Application to Make and Receive Calls through my Application.
I have been successfully able to Make Calls But Have not been Lucky Enough to Receive Incoming Calls Successfully.
Could you Please Provide me the Code to Monitor and Receive Incoming Calls?
Also, The Code Guru (Author) has mentioned "I will also include the full project as a download", Did anyone find on this Page or I am Blind enough to miss it?
Regards,
SAM.
|
|
|
|
|
Good afternoon!
I've done a program that reconized who calls. I get the incoming call number and search this into my database.
I've use the information of this article and works.
but I've a problem, when this programs is running X time, and after X time stops working. I don't know what happens, but is really strange. The aplication is like dead, but if you look the process information which is running into the pc (ctrl+alt+supr) you can see that my program is still running.
Someone have to solve this kind of problem???
I've thinking to restart automatically the program each hour, but ... I don't know if is is a good idea, because first I've to kill the program...
well, if some one has undertood me and could help I'll be very glad.
sorry for my bad english.
thank you
gemma
|
|
|
|
|
I can think of one scenario that could cause your problems,
try to make sure you dispose of your resources correctly (set unwanted references to null).
"Imagination is more important than knowledge.."
{Albert Einstein}
|
|
|
|
|
which name space do i need to include for TTERMINAL
|
|
|
|
|
how actually can I answer the incoming calls from a "Windows Application"
I wanted to notify me by an audio file , and give me the caller phone number ...
I think this could be done by putting the right code in "CallInfoEvent" subroutine , but none is executed when the phone rings.
by the way .... my modem is correctly connected to the phone cable , in case you wanted to tell me this ..
and one more thing ...
some events fire when I connect to the internet ,
or make a call by (C:\Windows\System32\dialer.exe)
any help please
|
|
|
|
|
hi,
can I save on my PC the faxes I receive on my phone line using TAPI ?
If yes, how can I catch the faxes ?
Thanks.
|
|
|
|
|
Hi,
I Have a question. How I can get sound when I call to a phone numer). When I dial the number, the phone device ring ok, but when I answer the a I have no sound. I' dont know wath Have I do to get sound. Please your help.
thanks in advance.
PD: Excuse my english, it's very poor
"To the shadow of the last tree will be a son of the bitch"
|
|
|
|
|
Did you know this? We tried to use TAPI version 3.x, but we changed to TAPI version 2.x because of a wrong event model in the COM-wrapper.
TAPI version 3.x never works for us in productive environment.
http://support.microsoft.com/default.aspx?scid=kb;en-us;841712[^]
Do you have any other experience with that?
Thanks.
|
|
|
|
|
Hi,
I have a telecom switch that have a callingcard servie, I dial a the DID from my phone and when I hear the ring I hung up, the switch call me immediately.
Can I do this from TAPI3, do I need to change the callerID, can I send a virtual callerID?
|
|
|
|
|
|
Hello All,
I need to know if there is a way to identify a call!
I want to open a window for each call, and close the correct window when the call is closed or terminated.
Normaly when there is only one call no problem, but I aspect a lot of calls during the same time.
Regards
Carsten
|
|
|
|
|
Hi,
first I'm a very early beginner with TAPI ad vb.net
In my testing code, I see incoming calls and can make a call.
But all events are triggerd very often. I can't see a system in this!
Is there a way to see, that this events are all based on the same call, if so?
My idea, I open a window for every call. But only for different calls.
regards
Carsten
modified on Thursday, June 5, 2008 1:03 PM
|
|
|
|
|
Hello Code Guru,
I'm currently working with your code example, but i encounter a strange error. I'm using visual studio 2005. When I first run my project the events fires as expected. I also got the disconnected event when I finish the phone call. But after that, nothing more happens. When the next call arrives NO event will be firing up and also no 3th party TAPI tool will get the next call. When I call the .shutdown method in the disconnected event handler, it's not getting much better, however 3th party TAPI tools will then get the next TAPI calls as usual. My program not ... But when I stop the project and run it again, it will work for the first call again. So I believe the call is not properly finished in some way, however, every code i found for .net has the same problems, but commercial 3th party tools don't. so there must be a way. Can you, or anyone other please point me in the right direction?. I've not much experience with TAPI at all, but this is a very strange behavior in my opinion. To be complete, I’m using the TAPI Drivers for Fritz BOX by AVM, a well known Manufacturer here in Germany.
Any help is greatly appreciated
Thanks
RoSch
|
|
|
|
|
I have the code verbatim as posted and I am getting a strange error when the following call is made:
CallInfoObject.Call.CallInfoString(CALLINFO_STRING.CIS_CALLERIDNAME)
Error HRESULT E_FAIL has been returned from a call to a COM component...
The Trace stack portion is below:
at Herbalife.VBCity.TAPI.VBTAPI.CallStateEvent() in C:\Documents and Settings\Ken\My Documents\Visual Studio Projects\Copy of Herbalife\tapi.vb:line 159
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()</StackTrace><ExceptionString>System.Runtime.InteropServices.COMException (0x80004005): Error HRESULT E_FAIL has been returned from a call to a COM component.
at TAPI3Lib.ITCallInfo.get_CallInfoString(CALLINFO_STRING CallInfoString)
Any Ideas?
TIA
Ken Yannitell
|
|
|
|
|
i run ur the projct in vs2005 . i got a message "Attempting Mannaged execution inside OS Loader Lock. do not attempt run a manage code inside a DllMain or image initialization function since doing so may cause the application to hang..
|
|
|
|
|
this is my last year project...i can answer the incoming call and also detect the DTMF tone but i dont hv any idea about how to play a WAVE file?? i am in a big problem..pls help me..if any body have sample code thn can u pls mail me at alok.dida@gmail.com or pls reply me..pls help me ..thnks in advance
|
|
|
|
|
Have u got any solution? if yes please can u post it here
Thanks in advance.
|
|
|
|
|
Greetings, thank you for such a solid work. I am trying to perform the SIMPLE task of calling a phone number and detecting the button that is pressed on the other end. I used the Julmar.ITAPI library at first but couldn't get it to work with events. I switched to the Tapi3Lib, and studied your code. It all works great, i can make the call. However, as soon as I add the Sub that handles the Tapi.Event, everything stops working! I get an error message about InteOp Services. If I take out the sub, everything works fine and I can make the call.
So -> Event Handler Sub, program crashes, Tapi_obj not initalized
-> No event handler sub, program proceeds, tapi_obj is initalized correctly, and call is made.
HELP!
I attached my code below
Imports TAPI3Lib
Public Class frmCallingNow
Private str_buzzer As String
Private call_obj As ITBasicCallControl
Private addr_obj As ITAddress
Private WithEvents tapi_obj As TAPI
Private Const MediaAudio As Integer = 8
Private Const MediaModem As Integer = 16
Private Const MediaFax As Integer = 32
Private Const MediaVideo As Integer = 32768
Private RegCookie As Integer
Public Sub New(ByVal hndlToGodModule As GodModule, ByVal buzzer As String)
.
.
.
'TAPI3 CODE
Try
Dim MediaTypes As Integer
tapi_obj = New TAPI3Lib.TAPI()
tapi_obj.Initialize()
Dim AddressCollection As ITCollection = tapi_obj.Addresses()
For Each Address As ITAddress In AddressCollection
If Address.State = TAPI3Lib.ADDRESS_STATE.AS_INSERVICE Then
Dim mediaSupport As ITMediaSupport = Address 'extract media support interface from the address
MediaTypes = mediaSupport.MediaTypes
mediaSupport = Nothing
If (MediaTypes And MediaModem) = MediaModem Then
'address is data modem
If (MediaTypes And MediaAudio) = MediaAudio Then
'this address is a voice-supporting fax/modem: SELECT THIS ADDRESS
addr_obj = Address
Exit For
End If
End If
End If
Next
If Not (addr_obj Is Nothing) Then 'If we have an address
RegCookie = tapi_obj.RegisterCallNotifications(addr_obj, True, False, MediaTypes, 1) 'Register the notifications for the selected address
'Specify which notifications we are interested in
tapi_obj.EventFilter = (TAPI_EVENT.TE_DIGITEVENT Or TAPI_EVENT.TE_TONEEVENT Or TAPI_EVENT.TE_CALLSTATE)
call_obj = addr_obj.CreateCall(buzzer, TAPI3Lib.TapiConstants.LINEADDRESSTYPE_PHONENUMBER, MediaTypes)
call_obj.Connect(False)
Else
MessageBox.Show("No Address Selected", "TAPI Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
End If
Catch ex As Exception
MessageBox.Show(ex.ToString, "TAPI Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
End Try
End Sub
'TAPI3Lib CODE
' IF I REMOVE THE COMMENTS OFF OF THE FOLLOWING BLOCK, THE APP CRASHES WITH INTEROP EXCEPTION
'Private Sub MY_TAPI_EVENTS(ByVal TapiEvent As TAPI3Lib.TAPI_EVENT, ByVal pEvent As Object) Handles tapi_obj.Event
' Select Case TapiEvent
' Case TAPI3Lib.TAPI_EVENT.TE_DIGITEVENT
' MessageBox.Show("Digit input = " + pEvent.ToString)
' Case TAPI_EVENT.TE_TONEEVENT
' Case TAPI_EVENT.TE_CALLSTATE
' End Select
'End Sub
Private Sub lbl_CallingNowForm_Cancel_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lbl_CallingNowForm_Cancel.Click
If tapi_Obj Is Nothing Then
Me.DialogResult = Windows.Forms.DialogResult.Cancel
Else
tapi_Obj.Dispose()
addr_obj.Dispose()
call_obj.Dispose()
Me.DialogResult = Windows.Forms.DialogResult.Cancel
End If
End Sub
End Class
|
|
|
|
|
Update:::
Ok, I fixed the InterOp Problem.. It seems that I couldn't instantiate a new TAPI object like this
tapi_obj = new TAPI3Lib.TAPIClass
Instead I had to do what is suggested in the article above.
I'm still trying to find which event is raised when a button is pressed on the phone... I'm testing with a Nokia Cell phone, and I'm switching to land line. will keep you guys posted
|
|
|
|
|
Abulfar wrote:
tapi_obj.EventFilter = (TAPI_EVENT.TE_DIGITEVENT Or TAPI_EVENT.TE_TONEEVENT Or TAPI_EVENT.TE_CALLSTATE)
that line should come before you register for call notification in order to receive your events.
"Imagination is more important than knowledge.."
{Albert Einstein}
|
|
|
|