Bug 10616 - GetGroups() method on ABAddressBook always return empty
Summary: GetGroups() method on ABAddressBook always return empty
Status: VERIFIED FIXED
Alias: None
Product: iOS
Classification: Xamarin
Component: Xamarin.iOS.dll ()
Version: 6.0.x
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: 7.0.6
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2013-02-24 00:06 UTC by Jeffrey Lewis
Modified: 2013-12-13 11:03 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
VERIFIED FIXED

Description Jeffrey Lewis 2013-02-24 00:06:22 UTC
GetGroups() method on ABAddressBook always return an empty array when tested on a device (iPhone 4S iOS6.1) with multiple groups in address book (iPhone Contacts group and Facebook group).

Sample code:

ABAddressBook iPhoneAddressBook = ABAddressBook.Create(out err);

if(err != null)
    HandleError(err);

ABGroup[] groups = iPhoneAddressBook.GetGroups();
Console.WriteLine(groups.Length);
Comment 1 Rolf Bjarne Kvinge [MSFT] 2013-02-26 17:14:23 UTC
Can you try the ABUIGroup [1] sample from Apple to see what you get there?

I always get an empty list of groups (even if I add a new group with this sample and then restart the app) - so this doesn't look like it's a problem with Xamarin.iOS.

http://developer.apple.com/library/ios/#samplecode/ABUIGroups/Introduction/Intro.html#//apple_ref/doc/uid/DTS40011307
Comment 2 PJ 2013-11-19 17:05:39 UTC
This bug has been in the NEEDINFO state with no changes for the last 90 days. Can we put this back into the NEW or CONFIRMED state, or are we still awaiting response?

If there is no change in the status of this bug over the next two weeks, this bug will be marked as NORESPONSE.
Comment 3 Jeffrey Lewis 2013-11-19 18:17:54 UTC
Solved using addressBook.GetAllSources()
Comment 4 PJ 2013-12-11 18:45:42 UTC
This fix is planned to be released with Xamarin.iOS 7.0.6, which should hit the beta channel before December 23rd.
Comment 5 Mohit Kheterpal 2013-12-13 11:03:18 UTC
As per comment 3, this issue is resolved.

Hence closing this issue.