I have an app that transfers calls but from version 6+ it does not work I've tried this:
btn_transfer.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Intent intent = new Intent(Intent.ACTION_CALL);
Uri uri2 = Uri.parse("tel:4");
intent.setData(uri2);
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
if (ActivityCompat.checkSelfPermission(ServicioCallerOverride.this, Manifest.permission.CALL_PHONE) == PackageManager.PERMISSION_GRANTED) {
startActivity(intent);
}
}
});
The result is: The transfer could not be made. It does not give an error in the application.