1
안드로이드
에서 내가 사용한 커서 (+ 페이스 북 구글) :모든 동기화 연락처를받는 방법으로 안드로이드 연락처 목록에서 모든 연락처를 얻기를 위해
ContentResolver cr = getContentResolver();
Cursor cur = cr.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null);
if (cur.getCount() > 0) {
while (cur.moveToNext()) {
String id = cur.getString(cur.getColumnIndex(ContactsContract.Contacts._ID));
String name = cur.getString(cur.getColumnIndex(ContactsContract.Contacts.DISPLAY_NAME));
if (Integer.parseInt(cur.getString(cur.getColumnIndex(ContactsContract.Contacts.HAS_PHONE_NUMBER))) > 0) {
Cursor pCur = cr.query(ContactsContract.CommonDataKinds.Phone.CONTENT_URI, null, ContactsContract.CommonDataKinds.Phone.CONTACT_ID + " = ?", new String[] { id }, null);
while (pCur.moveToNext()) {
phoneContactList.add(name);
Log.i("Contact List", name);
}
pCur.close();
}
}
내 연락처 목록은 페이스 북과 동기화됩니다. 하지만 연락처 목록에서 나는 페이스 북에서 연락을 받고 있지 않습니다.
모든 동기화 연락처를 가져 오는 방법은 무엇입니까? 어떤 사람은이 문제에 실수를 한단다 단지의 경우
가능한 [Android 및 Facebook 연락처 선택기 발행자] (http://stackoverflow.com/questions/8138032/android-and-facebook-contact-picker-issuer) – thepoosh