iphone - Not able to access Contacts in iOS7 -


i using following code contacts user's phone

cferrorref  error; __block bool accessgranted; abaddressbookref myaddressbook = abaddressbookcreatewithoptions(null,&error); abaddressbookrequestaccesswithcompletion(myaddressbook, ^(bool granted, cferrorref error)   { if (!accessgranted && !granted) { alertviewdeny = [[uialertview alloc]initwithtitle:@"deny access" message:@"deny" delegate:self cancelbuttontitle:nil otherbuttontitles:@"cancel", nil]; [alertviewdeny show]; [alertviewdeny release]; } else { nsarray *allpeople = (nsarray *)abaddressbookcopyarrayofallpeople(myaddressbook);      dlog(@"allpeople %@",allpeople); } 

in output getting //only ios7 , working ios6.

allpeople( )


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -