I am trying to add a contact to the phone it开发者_运维问答self.
i have the code working for adding it to say gmail or facebook account but what is the accounttype and name for phone.I did a list of all accounts and there is nothing like phone in there.
thanks
If you pass null
as the account's type and name, it will be stored in phone's address book. But some devices add such contacts to the first available account or to the address book if no accounts were added.
First, read up on ContentProvider: http://developer.android.com/guide/topics/providers/content-providers.html
Then, read this: http://developer.android.com/resources/articles/contacts.html
精彩评论