Android Question Press Key while in Phone Call from App

Discussion in 'Android Questions' started by aaronk, Feb 24, 2015.

  1. aaronk

    aaronk Well-Known Member Licensed User


    I am trying to make a phone call within my app but display my app while the phone call is being made and then when the call is answered to press some keys.

    I have been able to do some of this so far using the PhoneEvents in a service like below:

    Sub Process_Globals
    Dim PE As PhoneEvents
    End Sub

    Sub Service_Create
    Dim PhoneId as PhoneId
    End Sub

    Sub Service_Start

    End Sub

    Sub PE_PhoneStateChanged (State As String, IncomingNumber As StringIntent As Intent)
    If State = "OFFHOOK" Then StartActivity(PhoneUI)
    End Sub
    Sub Service_Destroy
    End Sub
    The above will detect if the call is being made..
    So from a Activity (such as the Main Activity) I have a button that will call a phone like:

    Sub Button1_Click
    Dim ph as PhoneCalls
    StartActivity("12345678")) ' Replace this with the number I want to call
    End Sub
    However lets say the person at the other end answers the call but I want to press 123 while in the call. (bit like VoiceMail where you press a key to delete the VoiceMail)

    Is there a way within my app and while the call is answered to press 123 as I haven't been able to work it out ?
  2. Erel

    Erel Administrator Staff Member Licensed User

    It is not possible.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice