I am attempting to retrieve the names and phone number(s) of all contacts and put them into arrays with Swift in iOS. I have made it this far:
In swift 3 you can get direclty
if item.isKeyAvailable(CNContactPhoneNumbersKey){ let phoneNOs=item.phoneNumbers let phNo:String for item in phoneNOs{ print("Phone Nos \(item.value.stringValue)") }