开发者

Is it possible to insert the two new contacts with same display name on Android 2.2?

开发者 https://www.devze.com 2023-01-29 05:00 出处:网络
I need to insert two new contacts with same display name. But all other fields are different. How its possible?

I need to insert two new contacts with same display name. But all other fields are different.

How its possible?

I tried to insert like this, but both contacts are conflicted开发者_开发百科 on Android 2.2 contacts.


Android's 2.x Contacts API will aggregate 2 raw contacts with the same name by default. See the section Automatic aggregation in Using the Contacts API.

What you need to do is disable automatic aggregration, which is also described in that very useful article. You merely have to set your RawContact record's AGGREGATION_MODE value to AGGREGATION_MODE_DISABLED.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号