Questions tagged [contactscontract]

Android's Contacts API is defined in the android.provider.ContactsContract and related classes.

The Android platform provides a Contacts API for managing and integrating contacts from multiple accounts and from other data sources.

To handle overlapping data from multiple sources, the contacts content provider aggregates similar contacts and presents them to users as a single entity.

ContactsContract defines an extensible database of contact-related information. Contact information is stored in a three-tier data model: Contacts, Raw Contacts and Data.

More information can be found in the documentation for the ContactsContract class.

551 questions
-1
votes
2 answers

memory leak issue regarding contact list in phone book

I am loading the contact list from phone whenever click Tab. it works fine at first touch, but it leads memory problem from second time. How should I prevent this issue? here is the code. String sortOrder = ContactsContract.Contacts.DISPLAY_NAME …
wjcoder
  • 29
  • 5
-1
votes
1 answer

how to import a contact name and number from csv file to android phone by programmatically

I am new to android i am in need to read a contact details as contact name and phone number form csv file and store it into android phone by pro grammatically please help any one . thanks in advance
-1
votes
3 answers

selecting multiple contacts using checkbox

I am trying to create a application for android. in which at one point i need to open a activity i need to display all the contacts on user's phone in a listview with checkbox, so that multiple contacts can be selected. I have written a code which…
Tapan Desai
  • 848
  • 2
  • 14
  • 36
-1
votes
2 answers

show List of all contacts with phonenumber in android?

Possible Duplicate: How to read contacts on Android 2.0 Is it possible to create a List of my all Contacts with PhoneNumber in phone book , but condition is if it don't have PhoneNumber then it shows only name for that record. I want all this in…
lakhani
  • 128
  • 2
  • 13
-1
votes
1 answer

Update more than one phone number contact

I need to update more than one phone number for the same contact. I can update only one phone number, but I don't know how I can update 2 for example Here is my code... String stEtPhone = etPhone.getText().toString(); values.clear(); String…
-2
votes
1 answer

Content Resolver throws Null Pointer Exception while inserting into DATA.CONTENT_URI

I am using below code to add custom Mimetype in Android Contacts . This code is throwing an error on the below line getContentResolver().insert(ContactsContract.Data.CONTENT_URI, values); java.lang.NullPointerException: Attempt to invoke virtual…
-2
votes
2 answers

fetch distinct and unique contacts from the phone avoiding duplicity

i want to retrieve the contact list from the phone avoiding any duplicates. i think it is retrieving the contacts from google account,phone or sim. so how to avoid the duplicate contacts. though a contact can have same number but with different…
anupriya
  • 9
  • 3
-2
votes
1 answer

How to get Recently Added / Edited / Deleted contact from Phonebook in android

I making an application in which my requirement is to get the Recently Added or Edited or Deleted Contact in Phonebook. So is there is way to achieve this. Any help will be appreciated.
droidd
  • 1,361
  • 10
  • 15
-2
votes
2 answers

Android - How to get saved contact id

I want to get saved contact id and i used following way to retrieve it but the problem is it's returning the wrong id. public static String addContact(FragmentActivity activity, String displayname, String mobilenumber, String homeemail) { String…
user3800832
  • 421
  • 2
  • 8
  • 22
-3
votes
1 answer

How to upload total list of phone's contact photo to server using Android?

I am using ContactsContract to retrieve phone's contact details along with Photo. And it's working fine. But now I need to upload those list of contact's photos to my server, all at once. How can i do that ? Any help is appreciated. Please someone…
Light Infinite
  • 35
  • 1
  • 1
  • 9
-3
votes
1 answer

Store contacts' name and phones into an ArrayList

I cannot make any solution work... The result is always an app crash. I successfully made a listView, added items and got the selected ones, but I miss making the elements of the list the contacts' names instead of random ones. Once selected, I…
1 2 3
36
37