0
我試圖找回因此使用如何從電話號碼中檢索ID?
String addrWhere = Contacts.Phones.NUMBER + " = " + userNumber;
String id = "";
Cursor c = mContext.getContentResolver().query(
Contacts.Phones.CONTENT_URI,
new String[] { Contacts.Phones._ID }, addrWhere, null, null);
try {
if (c.getCount() > 0) {
c.moveToFirst();
id = c.getString(0);
Log.i("IDS", id);
}
} finally {
c.close();
}
return id;
任何人都可以讓我知道我在這個錯誤電話號碼?
請註明相關位,而不僅僅是一個鏈接(絕對* *包含的鏈接,但也* *引號):http://meta.stackexchange.com/questions/8231/are-answers-that- just-contain-links-elsewhere-really-good-answers – 2010-11-23 11:45:32