How to block calls in Android/Reject incoming calls in android/program to block unwanted calls in Android/Android call blocking example/blacklist example in android Create an interface ITelephony.java with package name com.android.internal.telephony ITelephony.java package com.android.internal.telephony; public interface ITelephony { boolean endCall(); void answerRingingCall(); } Create a broadcast receiver and get incoming number from intent. CallReceiver.java package com.example; import java.lang.reflect.Method; import com.android.internal.telephony.ITelephony; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.os.Bundle; import android.telephony.TelephonyManager; public class CallReceiver extends BroadcastReceiver{ private String incomingnumber ; @Ov...
If you are a beginner , then this blog will help you to dive into the basics.