[mapguide-users] Re: Need to draw lines, points, possibly polygons to database

GordonL gordon.luckett at arrowgeomatics.com
Tue Oct 4 20:36:07 EDT 2011

There are many ways to do this - it requires both C# and javascript client

If you are using Basic web layout there is an API to digitize and a handler
so you can loop over each feature to get the coordinates.  They will be
returned in whatever coordinates your map is currently in.

If you are using FUSION, there are some functions that you can use in the
MapGuide.js file in the www\fusion\layers\MapGuide\ folder that totally
match the Ajax viewer API where you can catch the points in the handler.

Once javascript has the points you can post them anywhere you wish.

If you are using C# you can use the MapGuide Server API to edit the dataset.  

You could bypass mapguide at this point and post the coordinates to an
insert statement in PostGIS, SQL Server or Oracle.

Or you could continue to use Javascript and post/put the coordinates to
mapguide using GeoRest.  You just have to format them in XML and put/post
them to the site and the source data, regardless of source, will be updated. 
You data could be SHP, SDF, or database.  georest.org
(I use this when I have to update SHP and SDF files)


View this message in context: http://osgeo-org.1803224.n2.nabble.com/Need-to-draw-lines-points-possibly-polygons-to-database-tp6860154p6860584.html
Sent from the MapGuide Users mailing list archive at Nabble.com.

More information about the mapguide-users mailing list