简体   繁体   English

查看/编辑 Android 上的联系人

[英]View / Edit Contact on Android

I am trying to add these functionality in my Android app:我正在尝试在我的 Android 应用程序中添加这些功能:

1) Get A list of suggested contacts from a Web Service and Display them in a list view - This I have implemented and working fine 1) 从 Web 服务中获取建议的联系人列表并在列表视图中显示它们 - 我已经实现并且工作正常

2) When User selects any of these contacts I want to present them in Native Contact View. 2) 当用户选择这些联系人中的任何一个时,我想在本机联系人视图中显示它们。 My fried who is iPhone developer was able to do this with help of ABPerson class which provides feature to display the contact in native contact view page without adding the contact to contact list.我的 iPhone 开发人员在 ABPerson class 的帮助下能够做到这一点,它提供了在本机联系人视图页面中显示联系人而不将联系人添加到联系人列表的功能。 I am not able to find any such API in Andoid.我在 Andoid 中找不到任何这样的 API。 Please suggest.请建议。

3) When User want to edit any contact in the above list, I am able to present Edit Contact activity from native Phone Book app. 3)当用户想要编辑上述列表中的任何联系人时,我可以从本机电话簿应用程序中显示编辑联系人活动。 This is working fine, but I am not able to remove the Done and Revert button.这工作正常,但我无法删除完成和恢复按钮。 Unfortunately due to this, if user click on Done that contact is added to phone, however, what I want to do here is that, user can modify the data and I will keep it in the memory till the export process starts.不幸的是,由于这个原因,如果用户单击完成该联系人已添加到手机,但是,我在这里要做的是,用户可以修改数据,我会将其保存在 memory 中,直到导出过程开始。 During the export process I will insert these records in the Phone Book.在导出过程中,我会将这些记录插入到电话簿中。

Please suggest me how can I do this.请建议我该怎么做。

I would advise you look over the BusinessCard sample and ContactManager sample posted on the Android developer site.我建议您查看 Android 开发人员站点上发布的BusinessCard 示例ContactManager 示例

Reading carefully through both of these is what helped me understand exactly what's going on in the contacts API.仔细阅读这两本书有助于我准确了解联系人 API 中发生的事情。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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