I am developing a Caller Screen App in which I have two buttons accept and reject the call. Button reject is working properly, but the accept button is not working in all android version
iTelephony= (ITelephony) context
.getSystemService(Context.TELECOM_SERVICE);
try {
iTelephony.answerRingingCall();
} catch (RemoteException e) {
e.printStackTrace();
}