Creating a Basic Google Map
Now, with just a few quick steps, you'll produce a functional Google Map.
The map will show you the locations of Harley-DavidsonMotorcycle Dealerships in the state of Illinois:
-
In your report definition, add a Google Map element and configure
its attributes, as shown above.
- Add a Map Markers element below the Google Map element and configure its attributes as shown above. The sample database you're working with includes columns named "Latitude" and "Longitude", which contain positioning data. Later on, you'll discover how to get that data from Google if you don't have it.
-
Add a DataLayer.XML element below the Google Map Marker and
configure its attributes as shown above. The XML data file should be in
the drop-down list of choices for this attribute.
- Finally, add a Compare Filter element beneath the datalayer, as shown above, and set its attributes as shown, to filter out all records except those where the State column equals "IL", the postal abbreviation for Illinois.
Now you're ready to create your first Google Map. Save and browse your
application. The results should look something like this:
At this point, take some time to play with this map:
-
Change the Compare Filter element's attributes to get data for a
different state or for a city. Try Data Column = City, Compare Value =
Chicago, for example, and notice how the map scales to the data.
- Your cursor is a "hand" when it's over the map, meaning that you can pan the map by dragging the cursor. Give it a try!
- Change your Google Map element's Height and Width attributes and see what happens to the map scale.
Copyright © 2020 Logi Analytics, Inc. All Rights Reserved.