hi all below code giving me contact names and phone numbers from contact list but i need only phone numbers how can i solve the issue so give me solution 开发者_JAVA百科with full details without using android widget
public void getContacts(Context context){
context.startActivity(new Intent(Intent.ACTION_PICK, People.CONTENT_URI));
}
You can use the contactscontract api for that. For a reference on that api you can refer to http://developer.android.com/reference/android/provider/ContactsContract.html]1
For an example on how to use this api you can look at this example at google code http://code.google.com/p/android-contacts-contract-example/
精彩评论