aspose file tools*
The moose likes Android and the fly likes Get contacts by group name Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Mobile » Android
Bookmark "Get contacts by group name" Watch "Get contacts by group name" New topic
Author

Get contacts by group name

Jake Ikedichi
Greenhorn

Joined: Jan 04, 2013
Posts: 1
Hello
I am working on an android project. Trying to select all contacts belonging to a specific group. So, I'll like to get all the contacts in a group called Work
Below is my select statement

String select = "((" + Contacts.DISPLAY_NAME + " NOTNULL) AND ("
+ Contacts.HAS_PHONE_NUMBER + "=1) AND ("
+ Contacts.DISPLAY_NAME + " != '' ))";

I am passing the above select statement to a CursorLoader object, which works fine for getting all contacts. But I will like to add another clause like "(" + Contacts.GROUP_NAME + "=Work)" for getting only the work group
Please help..Thanks in advance
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Get contacts by group name