Article Preview
Buy Now
FEATURE
Maps Part 5 (Finding and Displaying Addresses)
Implementing Maps in Xojo desktop apps with the MapKitMBS plug-in
Issue: 18.4 (July/August 2020)
Author: Markus Winter
Author Bio: Markus is a Molecular Biologist who taught himself REALbasic programming in 2003 to let the computer deal with some exceedingly tedious lab tasks. Some call it lazy, he thinks it smart. He still thinks of himself as an advanced beginner at best.
Article Description: No description available.
Article Length (in bytes): 17,435
Starting Page Number: 67
Article Number: 18406
Resource File(s):
project18406.zip Updated: 2020-07-01 11:01:58
Related Link(s): None
Excerpt of article text...
Last time we found that it is better to use MapKit's
LocalSearch
rather thanGeoCoding
to find and show an address on a map (see Figure 1).Which brought up the question if there is any point in using
GeoCoding
at all? I have to say that as far as searching for an address, business, or point of interest is concerned: none that I can see. But there is one function that MapKit has not yet taken over fromGeoCoding
:reverse-lookups , when you need to turn coordinates into a human readable location.As
LocalSearch
andGeoCoding
are using different databases I wondered about any differences in outcomes that might result. So to see how the information from MapItem's placemark compares with a reverse-lookup using those same coordinates with aGeoCoder
, I searched for KFC, and from the suggestions, picked the one in Greenlane, a suburb of Auckland. I supplied the coordinates from theMapItem
to aGeoCoder
object:
geocoder.reverseGeocodeLocation( mapItem.placemark.location, GeoCoderCompletionHandler )
...End of Excerpt. Please purchase the magazine to read the full article.