In my app I export some data to the address book in order to create some new contact entries. I can export everything I want to without problem, except Facebook and Twitter addresses. I'm completely lost on these two.
Here's some code I'm using to export non-Facebook/Twitter data that DOES work:
ABMutableMultiValueRef multiPhone = ABMultiValueCreateMutable(kABMultiStringPropertyType);
ABMultiValueAddValueAndLabel(multiPhone, (__bridge CFTypeRef)(thePhoneMobile), kABPersonPhoneMobileLabel, NULL);
ABMultiValueAddValueAndLabel(multiPhone, (__bridge CFTypeRef)(thePhoneHome), kABHomeLabel, NULL);
ABRecordSetValue(newPerson, kABPersonPhoneProperty, multiPhone, NULL);
CFRelease(multiPhone);
Here's how I'm trying to export Facbeook which does NOT work:
ABMutableMultiValueRef multiSocial = ABMultiValueCreateMutable(kABMultiStringPropertyType);
ABMultiValueAddValueAndLabel(multiSocial, (__bridge CFTypeRef)(theFacebook), kABPersonSocialProfileServiceFacebook, NULL);
ABRecordSetValue(newPerson, kABPersonSocialProfileProperty, multiSocial, NULL);
CFRelease(multiSocial);
Where am I going wrong?