Skip to main content

Posts

Showing posts from July, 2011

Find a person using his addressbookrecordID only !!!

HI All, Today i implement a good thing that i think i should post on the blog i make a function by whcih you can display address book full information just using the  RecordID of a user in addressbook here is the function by which you can just fetch all information about a person if you have only his recordID from address book .     ABAddressBookRef ab = ABAddressBookCreate ();     ABPersonViewController *navCtlr = [[ ABPersonViewController alloc ] init ];          ABRecordRef person = ABAddressBookGetPersonWithRecordID (ab, RecordID );      navCtlr . displayedPerson = person;      navCtlr . addressBook = ab;     navCtlr. allowsEditing = YES ;     [[ self navigationController ] pushViewController : navCtlr  animated : YES ]; this will open the controller that will have full information against the record id of that particular user. Thanks,

dateFromString returns nill!!!

HI , This is called a good beginning - when i was working on a issue i stuck out on a issue when i try to convert a string in  to NSDATE and first i thought i doing some wrong thing but after doing some R & D i got this function always returns -nill value either you are giving any format ,Firstly i tried to give a nslocale but here it is also failed so then i got a technical answer of apple regarding this function and then try it on the lower os but still i failed so .I can say i get to know a bad function in the ios 4.2 . Here is the link of the technical doc regarding the query - Apple technical doc and if you want to try some more by your hand then try new string format . by the way i tried it in these ways [ outformatter setDateFormat : @ "MMM dd, yyyy" ] ; [ outformatter setDateFormat : @ "MMM d, yyyy" ] ; [ outformatter setDateFormat : @ "MMM dd, YYYY" ] ; some time it gives error on small year alphabet. Finally what i got a nonworking