I need to retrive the contacts from device, but i need the contacts from
ContactsList aplication.
I'm get que Contacts:
Cursor cursor = cr.query(ContactsContract.Contacts.CONTENT_URI, new
String[] { ContactsContract.Contacts._ID,
ContactsContract.Contacts.DISPLAY_NAME,
ContactsContract.Contacts.HAS_PHONE_NUMBER },
ContactsContract.Contacts.IN_VISIBLE_GROUP + " = ?", new String[] { "1" },
null);
Ok, this way I have contacts. But when i get de details, phone number, for
example. Show repeated numbers:
Cursor cursor =
context.getContentResolver().query(ContactsContract.CommonDataKinds.Phone.CONTENT_URI,
null,
ContactsContract.CommonDataKinds.Phone.CONTACT_ID + " = ?", new String[] {
String.valueOf(contato.getAndroidId()) },
ContactsContract.CommonDataKinds.Phone.NUMBER + " COLLATE LOCALIZED ASC");
why this happens?
I need to retrive the contacts and details as the ContactsList application
device.
Thanks.
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
---
You received this message because you are subscribed to the Google Groups
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.