简体   繁体   中英

Redial multiple phone numbers android

I am in he middle of makinga custom dialer application. The application needs to dial different phone numbers within 5-10 seconds. The code pretty much looks like this but I need to call multiple numbers from an Array of Numbers. I need to force close a call activity to start another call activity.

private void quickDial(String[] numbers) {

   /*
    * LOOP with CountDownTimer code
    *
   */ 
   Uri number = Uri.parse("tel:" + number[i]);
   Intent dial = new Intent(Intent.ACTION_CALL, number);
   startActivity(dial);

}

Do you have any solution? Thanks :).

you need to use TelephonyManager to listen the phone state change. when detecting the phone call ended, start another dial activity.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM