Not getting Local/Device contact name and type using AccountManager android -


/**  * account available in phone , add list  */ private void getallaccounts() {     int counter = 0;     final accountmanager accmanager = accountmanager             .get(activity.this);     final account accounts[] = accmanager.getaccounts();      (int = 0; < accounts.length; i++) {         log.i(tag, "name " + accounts[i].name + ", type "                     + accounts[i].type);     } } 

i using above code getting available accounts of device. works on sony device not in samsung, micromax, htc. don't know reason behind this. if has idea please kindly me.

i not able local/phone/device contact name , type samsung, htc, micromax.

do

private string[] getaccountnames() {     maccountmanager = accountmanager.get(this);     account[] accounts = maccountmanager.getaccountsbytype(             googleauthutil.google_account_type);     string[] names = new string[accounts.length];     (int = 0; < names.length; i++) {         names[i] = accounts[i].name;     }     return names; } 

for more visit

http://developer.android.com/google/play-services/auth.html


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -