android Programming Glossary: people.number
Read all contact's phone numbers in android http://stackoverflow.com/questions/2356084/read-all-contacts-phone-numbers-in-android android I'm using this code to retrieve all contact names and phone numbers String projection new String People.NAME People.NUMBER Cursor c ctx.getContentResolver .query People.CONTENT_URI projection null null People.NAME ASC c.moveToFirst int nameCol.. null null People.NAME ASC c.moveToFirst int nameCol c.getColumnIndex People.NAME int numCol c.getColumnIndex People.NUMBER int nContacts c.getCount do Do something while c.moveToNext However this will only return the primary number for each contact..
How can I choose a phone number with Android's contacts dialog http://stackoverflow.com/questions/8612531/how-can-i-choose-a-phone-number-with-androids-contacts-dialog String name c.getString c.getColumnIndexOrThrow People.NAME String number c.getString c.getColumnIndexOrThrow People.NUMBER perrsonname.setText name Toast.makeText this name has number number Toast.LENGTH_LONG .show break Hey Updated Content..
Fetch Contacts in android application http://stackoverflow.com/questions/8785131/fetch-contacts-in-android-application i get the number associated with that contact. EDIT if i use this String number c.getString c.getColumnIndexOrThrow People.NUMBER line in code the I get following exception 01 09 13 33 23.008 E AndroidRuntime 786 FATAL EXCEPTION main 01 09 13 33 23.008..
Pick a Number and Name From Contacts List in android app http://stackoverflow.com/questions/9496350/pick-a-number-and-name-from-contacts-list-in-android-app or this code for getting all contacts but i cant have the number of contacts String contacts new String People.NAME People.NUMBER Uri contentUri People.CONTENT_URI Cursor cursor managedQuery contentUri contacts null null null String textContacts if.. textContacts textContacts cursor.getString cursor.getColumnIndex People.NAME cursor.getString cursor.getColumnIndex People.NUMBER n while cursor.moveToNext tv1.setText textContacts can anyone help me plz my android is 2.3.3 android android contacts..
|