aspose file tools*
The moose likes iOS and the fly likes How to get one instance of a person's latitude/longitude position, without getting constant updates? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Mobile » iOS
Bookmark "How to get one instance of a person Watch "How to get one instance of a person New topic
Author

How to get one instance of a person's latitude/longitude position, without getting constant updates?

Fayyazuddin Syed
Greenhorn

Joined: May 14, 2006
Posts: 10
I have a very basic question that is throwing me off right now. I want to get the user's location (i.e. current lat/lon co-ordinates) to be used to check against a sqlite database of location co-ordinates, and find the nearest ones. I am looking at the CLLocation class, but from what I can tell, I would use this class to get regular updates to the user's movement change which I don't need. I want to get the user's current latitude and longitude position, and based on that, determine what locations in the database are closest. How would I do this?

Thanks again for your time and help!

Sincerely;
Fayyaz
Alaa Nassef
Ranch Hand

Joined: Jan 28, 2008
Posts: 460
CLLocationManager has a startUpdatingLocation and a stopUpdatingLocation. Check out the class reference, the sample code (links in the class reference) and this tutorial.


Visit my blog: http://jnassef.blogspot.com/
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to get one instance of a person's latitude/longitude position, without getting constant updates?