转到编辑联系人的系统界面 编辑 添加
16lz
2021-01-23
如何跳转到编辑联系人的系统界面
分类:android 2011-07-01 17:05 208人阅读 评论(0) 收藏 举报 Intent intent=new Intent(Intent.ACTION_EDIT,Uri.parse("content://com.android.contacts/contacts/"+id));
startActivity(intent);
Intent intent = new Intent(Intent.ACTION_INSERT, Contacts.CONTENT_URI);
startActivity(intent);
应用跳转到系统添加联系人加好后再跳回当前应用
分类:android 2011-03-13 00:08 50人阅读 评论(0) 收藏 举报
[java] view plain copy
- publicvoidonCreate(BundlesavedInstanceState){
- super.onCreate(savedInstanceState);
- setContentView(R.layout.main);
- Buttonbutton=(Button)findViewById(R.id.email);
- button.setOnClickListener(newOnClickListener(){
- publicvoidonClick(Viewv){
- onClickSender();
- }});
- }
- privatevoidonClickSender()
- {
- try
- {
- UricontactUri=Uri.fromParts("mailto","liaojianguo19840726@gmail.com",null);
- IntentcontactIntent=newIntent(Contacts.Intents.SHOW_OR_CREATE_CONTACT);
- contactIntent.setData(contactUri);
- //PassalongfullE-mailstringforpossiblecreatedialog
- contactIntent.putExtra(Contacts.Intents.EXTRA_CREATE_DESCRIPTION,
- "liaojianguo19840726@gmail.com");
- //Onlyprovidepersonalnamehintifwehaveone
- StringsenderPersonal=null;
- if(senderPersonal!=null)
- {
- contactIntent.putExtra(Intents.Insert.NAME,senderPersonal);
- }
- startActivity(contactIntent);
- }
- catch(Exceptionme)
- {
- if(Config.LOGV)
- {
- }
- }
- }
- }
更多相关文章
- Android 获取系统相册中的所有图片
- Android 9.0设置系统语言
- CentOS64位系统使用Android虚拟机问题
- 【Android 系统开发】使用 Source InSight 阅读 Android 源码
- android 修改系统各种类型的声音的默认值和最大最小值
- Android 获得联系人信息
- 打开系统wifi设置界面
- WebView中调用系统相册或拍照上传
- cocos2dx android平台事件系统解析