1.启动startActivity(new Intent(this,B.class));
打电话给num
Intent intent = new Intent(Intent.ACTION_DIAL,Uri.parse("tel:"+num));
startActivity(intent);
(Intent.ACTION_PICK Uri.parse("content://contacts/people");
onCreate函数中
intent设置好了之后,使用
startActivityForResult(intent,常数SHOW_ONE);
跳转之前会触发调用onActivityResult,此函数中会根据show_one做出不同的操作
2.发送broadcastReceiver
Intent intent = new Intent("ACTION_BROADCASR");
sendBroadcast(intent);
3.启动服务
startActivity(new Intent(this,MyService.class));
转载于:https://blog.51cto.com/harwordhh/1028674