incoming-call

Rejecting Incoming call in android

孤者浪人 提交于 2019-11-27 11:43:46
I want to reject incoming in android, I have seen so many code from these links. Android: Taking complete control of phone(kiosk mode), is it possible? How? How to Reject a call programatically in android http://androidsourcecode.blogspot.in/2010/10/blocking-incoming-call-android.html http://androidbridge.blogspot.com/2011/05/how-to-answer-incoming-call-in-android.html?showComment=1361478035090#c5468022990217431781 But I am still unable to do it, can anybody tell me in simple and easy steps how to do it? Zubair In order to intercept your call you just have to: 1. Make a package named. com

Auto answer the incoming call programmatically?

穿精又带淫゛_ 提交于 2019-11-26 21:39:11
问题 I have the code for getting the number of the incoming call to a android phone. But I want to automatically answer the call when the incoming call is from a particular number. I found this code on the internet: public class ServiceReceiver extends BroadcastReceiver { private static final String TAG = null; @SuppressWarnings({"unchecked", "rawtypes"}) @Override public void onReceive(Context context, Intent intent) { Toast.makeText(context, "GOT SOMETHING", Toast.LENGTH_SHORT).show();

Stopping & Starting music on incoming calls

我的梦境 提交于 2019-11-26 15:05:19
I have implemented an Activity that plays media from a URL in android In order to add pause functionality when the incoming call is incoming I created a receiver that sets a a variable when the call is coming. The activity reads this variable and then pauses the music in its onPause() method and resets is when the call is done and the activity resumes the music in its onResume() method This works fine as long the activity has the focus. If I go back to home screen while the music is playing, and then the call comes, the activity's onpause is not called & hence i can' stop & start the music

Stopping & Starting music on incoming calls

社会主义新天地 提交于 2019-11-26 04:11:21
问题 I have implemented an Activity that plays media from a URL in android In order to add pause functionality when the incoming call is incoming I created a receiver that sets a a variable when the call is coming. The activity reads this variable and then pauses the music in its onPause() method and resets is when the call is done and the activity resumes the music in its onResume() method This works fine as long the activity has the focus. If I go back to home screen while the music is playing,

How can incoming calls be answered programmatically in Android 5.0 (Lollipop)?

陌路散爱 提交于 2019-11-26 03:21:09
问题 As I am trying to create a custom screen for incoming calls I am trying to programatically answer an incoming call. I am using the following code but it is not working in Android 5.0. // Simulate a press of the headset button to pick up the call Intent buttonDown = new Intent(Intent.ACTION_MEDIA_BUTTON); buttonDown.putExtra(Intent.EXTRA_KEY_EVENT, new KeyEvent(KeyEvent.ACTION_DOWN, KeyEvent.KEYCODE_HEADSETHOOK)); context.sendOrderedBroadcast(buttonDown, \"android.permission.CALL_PRIVILEGED\")

How to block calls in android

半腔热情 提交于 2019-11-25 23:43:50
问题 I want to block calls from few numbers, for that I want to write a app of my own. So what are the APIs which I should be using? Basically I want to get notified when a call comes, i want to compare numbers if it is what i want to block, i want to cut the call or mute it or if possible mute it and record it. 回答1: OMG!!! YES, WE CAN DO THAT!!! I was going to kill myself after severe 24 hours of investigating and discovering... But I've found "fresh" solution! // "cheat" with Java reflection to

How to detect incoming calls, in an Android device?

时光总嘲笑我的痴心妄想 提交于 2019-11-25 22:01:50
问题 I\'m trying to make an app like, when a call comes to the phone I want to detect the number. Below is what I tried, but it\'s not detecting incoming calls. I want to run my MainActivity in background, how can I do that? I had given the permission in manifest file. <uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/> Is there anything else should I provide in the manifest? public class MainActivity extends Activity { @Override protected void onCreate(Bundle