spacer1
spacer2 1_1 1_2
2_1
 Subscribe
 The MP2K Update!
 
 
 
 Magazine
Front Cover
What's New
Articles
News
Sample Data
Gallery
Advertise
About
 Features
MapPoint 2011
Press Releases
MapPoint Forums
Companies
Link to MP2Kmag
Wish List
MapPoint Trial
Authors
 Earlier Content
Past News Items
Past What's New Announcements
 Sponsors
 Order

MapPoint 2011

Programming MapPoint in .NET

MapPoint Book

  Spatial Community
SVG Tutorials
MapPoint

Map Visitors

  ARTICLES  


Using MapPoint in Foxpro

Charlie Parker shares a demo for using MapPoint within Foxpro that he originally prepared for a local Foxpro user group.

If you are a Visual FoxPro developer and want to learn how to use MapPoint in your applications, then here is a handy demo program on how to do that.

The demo program consists of a project, a main program and a form. The main program just kicks off the form. The form has all of the logic for handling MapPoint. The code in the form is commented so you can see fairly easily what it is doing.

Just a few notes on the operation: The "from" and "to" addresses are hard coded in the demo, but you can type in your own addresses or latitude/longitudes. If you enter a latitude/longitude, separate the values with a comma and be sure to check the box that says "Latitude, Longitude".

To have the program look up the location, click the "Compute Route" or the "Compute Distance" button. The times it took to find the locations, compute the route, compute the latitude/longitude, etc. are shown on the bottom of the form.

Remember, this is just a demo, so a minimum of error checking is done. For example, if you enter an invalid latitude or longitude, then you will get a MapPoint error since the program does not validate these before giving them to the MapPoint object. Also, there are a lot of things you can do with the MapPoint object that are not shown in this demo. However, this should get you started so you can try out some of the other features on your own.

Download it here: http://www.mp2kmag.com/downloads/foxprodemo.zip

NOTE: You must have both Visual FoxPro (any version) and MapPoint installed in order to run the demo program.

Discuss this story in the forum.

Author: Charlie Parker
Email: cparker(AT)fowlersoftware.com
URL: http://www.fowlersoftware.com
Charlie Parker has over 30 years of experience in designing, developing and supporting software applications. Since 1994, he has been a Project Manager for Fowler Software Design LLC, a custom software developer in Denver, Colorado. For more information on Charlie or on Fowler Software Design, see their web site at www.FowlerSoftware.com.



Google
 
MP2Kmag Internet


 Recent Discussion
-bingmaps: RT @ChrisPendleton: In case you missed my #location2012 talk, @OrdnanceSurvey has posted a recording: http://t.co/p5dcMTpN
-Upcoming WhereCamp Berlin 2012
-MapPoint for World Maps?
-Beginner stuck-what am I doing wrong?
-Mappoint 2011 Europe -> tooltip and update possibilities
-bingmaps: FREE BING MAPS EVENTS IN GERMANY: München https://t.co/pFJZxDdE Köln https://t.co/zerD99GK #bingmaps
-bingmaps: FREE EVENT: @BingMaps and @Beyond present a vision of the London 2012 Games: The Most Connected Games Ever. https://t.co/yEJ493OR
-Need Several Radius imported into a map
-Automatic generation of Drive Time zones around PushPins
-C# Code To Load Older COM Version
-Successful MapPoint Web Service (MWS) to Bing Maps Conversion
-bingmaps: @Sonray Please direct your question to our technical forum which is monitored by our developers: http://t.co/dEfOwFBC
-bingmaps: New Bird’s Eye Imagery & Streetside Coverage on Bing Maps! http://t.co/iJPu0McQ
-I have an excel spreadsheet that has number of houses on roads, can I link this to mappoint?
-Microsoft MapPoint 2011 Construction Data Update May 4th, 2012
-Mappoint 2011 and the built in database
-Using Excel and mappoint
-Extracting ZipCode With Lat/Long
-DataLink Problem!
-bingmaps: Integrating Bing Maps With WPF:http://t.co/HzdriaMs
-Mapping Bears
-Route Segments do not add up to complete route
-plotting pie charts by sales numbers
-Importing Live Data into Mapoint
-number of houses on a road?
 Resources
Browse GIS books and periodicals
Find a MapPoint Partner or Consultant
Real Estate Columbia For Sale By Owner


Want Your Site To Appear Here?

   © 1999-2012 MP2K. Questions and comments to: website@mp2kmag.com
  Microsoft and MapPoint 2002/2004/2006/2009/2010/2011 are either trademarks or registered trademarks of Microsoft.