iphone - Retrieving Latitude & Longitude CoOrdinates, Displaying in UILabel -


i interested in grabbing users current latitude , longitude coordinates, , displaying them literally nssstring in uilabel on view.

i don't need mkmapview or show graphically, display coordinates in uilabel. possible?

could provide starting block me?

thanks

ya, possible. import #import <corelocation/corelocation.h> , declare delegate <cllocationmanagerdelegate>. can values in following delegate mathod.

- (void)locationmanager:(cllocationmanager *)manager didupdatetolocation:(cllocation *)newlocation fromlocation:(cllocation *)oldlocation{      cllocationcoordinate2d location=newlocation.coordinate;     nsstring *s = [nsstring stringwithformat:@"%f,%f",location.latitude,location.longitude]; } 

Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -