android - Howto let a user change account data in 'Accounts and sync' -


there existing account on phone used sync service. account has settings user entered when created account. theses settings stored user data (--> maccountmanager.addaccountexplicitly(account, mpassword, userdata)).

the user should able change these settings. how can achieved? need standalone app change existing account data?

i guess user go 'settings'/'accounts , sync'/'myaccount' , should find menu entry 'modify account data'. menu entry should open same activity user has used enter data initially.

any hints push me in right direction?

this fooled me while - expected find getuserdata()/setuserdata() methods on account class, on accountmanager instead:

accountmanager = accountmanager.get(context); string mydata = am.getuserdata(account, someclass.my_data_key); mydata = "some new value"; am.setuserdata(account, someclass.my_data_key, mydata); 

check out the accountmanager setuserdata method docs more information.

cheers, andrew.


Comments

Popular posts from this blog

c++ - Is it possible to compile a VST on linux? -

java - Output of Eclipse is rubbish -

jquery - Confused with JSON data and normal data in Django ajax request -