Home > GPS > gps converter online

gps converter online

How can I write a program that writes a KML file from data in an excel sheet?

EXCEL data sheet to KML file
How can I write a program that writes a KML file from data in an excel sheet or any word program. I want to be able to use this code to be able to get coordinates from a gps device and then make a kml file to use in google earth. I will not have access to the internet so any online converter would not work for me
I am using excel 2007 windows 7. I was planning on writing a code on C# in visual studio if possible to do this, if not just doing it with excel sheet would be helpful too.

That should be quite simple. Without knowing which operating system this will run on and which programming language(s) you want to use I can’t give specifics, but it would go something like:

Open the excel file somehow (eg using office objects on a microsoft system, or opening the excel file as a database and using ADO)
Get the fields that you want to write to the kml file.
Since the kml file is a special case of xml, you can use an xml manipulation API (on windows MSXML for example) and just create the kml file.

KML reference: http://code.google.com/apis/kml/documentation/kmlreference.html
Office Web Components reference: http://msdn.microsoft.com/en-us/library/aa295264%28office.11%29.aspx


Share and Enjoy:
  • Print this article!
  • Digg
  • Sphinn
  • del.icio.us
  • Facebook
  • Mixx
  • Google Bookmarks
Categories: GPS Tags: , , , ,
  1. No comments yet.
  1. No trackbacks yet.