Golden Software Blog

Helping you learn more about the latest product information, tips, tricks, techniques, and customer stories so you can visualize data and communicate results with ease.

Geocode Locations from Google to create a route in MapViewer

When you are taking a road trip, have you ever wanted to determine to shortest route you could take from location to location? If you’re like most people, you will want to minimize your driving time, reduce your travel expenses, and spend more time at your destinations. If you have ever wanted to determine the shortest path you can take between locations, MapViewer may be just the tool that you were looking for!

Below I will use the geocoding functionality in MapViewer 7 to map the shortest distance path between each Major League Baseball stadium. If you were planning a summer road trip to visit every ballpark, this would be a great tool to help you plan your trip!

Follow the steps below to use geocoding to plot a route in MapViewer 7:

1.     Use the File | New command to create a blank project in MapViewer.

2.     Use the Map | Base Map command to add a base map of the lower 48 states.

3.     In the Import Boundary dialog, navigate to the MapViewer Samples directory. This is typically located here: C:\Program Files (x86)\Golden Software\MapViewer 7\Samples.

4.     Select the file US48Alb.gsb and click Open.

5.    In the Import Options dialog, click OK. The boundary of the lower 48 states will be displayed as your base map.

6.    Use the Tools | Geocode command to begin geocoding the address of the MLB stadiums.

7.     You will be prompted with a MapViewer dialog which says:


8.    Click Yes to accept this dialog and load your locations.

9.    In the Open Data File dialog, navigate and select the data file containing your addresses. Click Open. For this example, I used the data file MLB Stadium.xls.

10.   In the dialog shown below, you will need to assign the geocoding source information.



a.       Set the Geocoding data source option to Census-based Golden Software [.STR] street data.

b.      Specify the folder path where all of the street files (*.str) are located on your computer. These were provided on a supplemental CD titled United States Street Data that came with MapViewer 7.

c.       Set the Input columns to reference the Address in Column C: Address from the Excel file.

d.      Set the Output columns to reference Column E: Longitude and Column F: Latitude.

e.      Check the box next to Assign ZIP centroid to record with wrong address format or with no geocoding data file if possible. This will help to located address in your data file that are not included in the Golden Software street data.

f.        Click OK to begin the geocoding.

11.  An Interactive Geocoding dialog will be displayed showing the address that could not be located in the street data files. For each address that could not be located (left), an additional list of possible matches will be displayed on the right. If one of the listed streets is appropriate, select the street name that you would like to use.


12.  If you can find no suitable streets, click the button to Geocode Above Records and Assign ZIP Centroid if No Match. This will place the location using the ZIP code instead of the address. For most locations, this will provide a good approximation of the destination location.

13.  A Geocoding Report dialog will be displayed providing an overview of the geocoding, and asking if you would like to open the Pin Map dialog. Click Yes to create a Pin Map of your data.


14.  The Pin Map dialog will be displayed, allowing you to set and custom options for the Pin Map Click OK to create the Pin Map with the default settings. You will see pins placed at the location of each MLB stadium with the name of the team displayed as a label.

15. Now we need to create a route from one stadium to the next. Click Edit | Select All to select all of the objects on the Map.

16.   Once selected, use the Analysis | ShortestPath command to calculate the shortest path between all of the stadiums.

17.  In the Shortest Path dialog, set the Starting at location to where you would like to begin the trip. I will choose COLORADO ROCKIES, since that is the local team in Golden, CO.

18. Check the box next to Return path to start point, so that the starting and ending location will be the same.

19.  Check the box next to Trace the journey. This will add an outline of the path to the Map.

20.  Click the Calculate Shortest Path button. The path will be created. A table will display each leg or segment of the trip along with leg distance and the total trip length.

You can click the Create Report button if you would like to create and print a report with the route information.

21.  Click OK to close the dialog and add the path to your map.

MVGeoCode5Geocoded Route between MLB Stadiums using MapViewer 7

You now have a route of the shortest distance to travel to reach all of the Major League Baseball stadiums. As you can see, a few of the segments travel over the Gulf of Mexico, so I would recommend that you fly these segments of the trip!

Click here to download the example files used to create this post: MV

I hope that this gives you a good overview of the geocoding functionality in MapViewer. If you have any questions about using Geocoding, or if you have any other questions about using MapViewer, please contact Golden Software Support .



No comments made yet. Be the first to submit a comment
Sunday, 24 September 2017

Captcha Image

Subscribe To Our Blog

Most Popular

This week's new feature series is a tutorial on how to use the new coordinate system dialogs in MapV...
Over the years, one of the most common questions asked is “How can I get my contour map out of Surfe...
For more than 20 years, Surfer mapping software has been used by representatives of nearly all indus...

Exceeding expectations

Go to top