There are a couple of issues that I have found with the Mobile 1.6 SDK, and iOS 4.2.
1) Cannot pass contact object by reference: The following crashes
var retVal = null; var contacts = Ti.Contacts.getAllPeople(); for (var c=0; c < contacts.length; c++) { var contact = contacts[c]; Ti.API.debug('Name: ' + contact.fullName); if (contact.fullName) == 'baba smith') { retVal = contact; // This causes a crash. break; } }But this works:
var contacts = Ti.Contacts.getAllPeople(); for (var c=0; c < contacts.length; c++) { var contact = contacts[c]; Ti.API.debug('Name: ' + contact.fullName); if (contact.fullName) == 'baba smith') { return contact; } }2) contact email still crashes on the phone itself per: http://developer.appcelerator.com/question/98221/contact-email-on-ios
Your Answer
Think you can help? Login to answer this question!