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 501217
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T06:10:01+00:00 2026-05-13T06:10:01+00:00

when i run my application its get my location(Lat,logi) both new and old location.But

  • 0

when i run my application its get my location(Lat,logi) both new and old location.But i want to set oldlocation as new location when my application run first time.Because i want to calculate distance travel.
If i run my application it takes oldlocation where last location it get (saw distance travel 1 Km when i start application first time)

Hope u Understand
Thanks

  • 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-05-13T06:10:02+00:00Added an answer on May 13, 2026 at 6:10 am

    You can try to make some flag to indicate the first launching of your app. And then store this flag in NSUserDefaults. For example, if you cannot find your flag after launch, you show alert like “would you like to use your current location as start location?” if user choose YES, so you will update location and store it in the userDefaults. This is a persistent storage. Oh, perhaps, it even will be better to store not flag, but your start location coordinates.

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

Sidebar

Related Questions

I developed one swing application but each time you run application new window is
Background: My application should get its geographical location every X seconds, send the location
I want to have the current user GeoLocation but everytime I run my application
I'm not sure why, but whenever I run rake assets:precompile , application.js doesn't get
I need to get user location update when application is in background. I used
I have configured a Receive port and its location. When i run the BizTalk
I know it's possible to run a .NET application using a portable Mono executable
I have to run some other application from my program and hide it's form.
I recently uploaded my application to the android market however it's refusing to run
When I run below code, it's giving a message that: the application stopped unexcepctedlly

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.