Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8146129
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T13:53:33+00:00 2026-06-06T13:53:33+00:00

I have integrated to my project the mapkit framework and everything works fine. I

  • 0

I have integrated to my project the mapkit framework and everything works fine. I just show in a map the users current position like this :

mapView.delegate = self;
    mapView.showsUserLocation = YES;
    MKUserLocation *userLocation = mapView.userLocation;
    //numbers show map zoom. 500,500 = map stretches 500 meters to the North and the South of current location
    MKCoordinateRegion region =
    MKCoordinateRegionMakeWithDistance (userLocation.location.coordinate,1000,1000);
    [mapView setRegion:region animated:NO];

The problem is that i need to store to 2 variables the latitude and longitude of the current position but where are these values stored??

I tried to print the below but it gives me 0.000.

NSLog(@"Latitude: %f" , mapView.userLocation.coordinate.latitude);
NSLog(@"Longitude: %f" , mapView.userLocation.coordinate.latitude);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T13:53:35+00:00Added an answer on June 6, 2026 at 1:53 pm

    Implement this delegate method:

    - (void)mapView:(MKMapView *)mapView didUpdateUserLocation:(MKUserLocation *)userLocation
    

    Basically, the MapView will call this location once it has determined the user’s location. If you check userLocation on the fly, it’s not guaranteed.

    You can find the rest of the delegate methods in the MKMapViewDelegate Protocol Reference

    http://developer.apple.com/library/ios/#documentation/MapKit/Reference/MKMapViewDelegate_Protocol/MKMapViewDelegate/MKMapViewDelegate.html#//apple_ref/occ/intf/MKMapViewDelegate

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have integrated Facebook using library in my previous application and it works fine
I have successfully integrated the three20 framework in my project, and I have extended
I have just joined a on going project based on spring framework. It usage
I have some repositories integrated with apache. While importing small projects it works fine.
In my project,I have integrated Spring Security with CAS server authentication. Now my project
I have integrated in Hudson a maven 3 project calling following sequence: clean tomcat:redeploy
I've just started with orbeon and xforms for some project. I have Orbeon succesfuly
I have a web service project that needs to be set to use Integrated
I have a zend framework project. In the public folder I have js and
I have integrated jquery jeditable in my project. $(function() { $(.editable_textarea).editable(/articles/edit/, { indicator :

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.