1、跳转到拨号界面,代码如下:
1)直接拨打
Intent intentPhone = new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phoneNumber)); startActivity(intentPhone);
2)跳转到拨号界面
Intent intent = newIntent(Intent.ACTION_DIAL,Uri.parse("tel:" + phoneNumber)); intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); startActivity(intent);
2、跳转到联系人页面,使用一下代码:
Intent intentPhone = new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phoneNumber)); startActivity(intentPhone);