地址字段未从webservice获得其值。 我使用ABPersonViewController看地址簿有。
NSString *strAddress = [[NSString alloc]initWithString:aBook.Address]; ABRecordSetValue(person, kABPersonAddressProperty,strAddress, NULL);
帮助!
修改后的代码:
ABMutableMultiValueRef multiAddress = ABMultiValueCreateMutable(kABMultiDictionaryPropertyType); NSMutableDictionary *addressDictionary = [[NSMutableDictionary alloc] init]; [addressDictionary setObject:strAddress forKey:(NSString *) kABPersonAddressStreetKey]; ABMultiValueAddValueAndLabel(multiAddress, addressDictionary, kABHomeLabel, NULL); ABRecordSetValue(person, kABPersonAddressProperty, multiAddress, NULL); CFRelease(multiAddress);