[mapguide-users] Change xml files using the mapguide viewer API or mapguide web API

Chris Claydon chris.claydon at autodesk.com
Tue May 5 10:44:13 EDT 2009


You can use the MapGuide Web API to retrieve and save back the XML contents of resources in the repository. Take a look at MgResourceService::GetResourceContent() and MgResourceService::SetResource() in the API reference docs.

One thing worth noting when using SetResource() is that if you're simply updating the contents of an existing resource, the "header" parameter can be null. You just need to provide the resource identifier and a byte reader for the modified XML content.

Chris.

From: mapguide-users-bounces at lists.osgeo.org [mailto:mapguide-users-bounces at lists.osgeo.org] On Behalf Of Nick Sebastyan
Sent: Tuesday, May 05, 2009 1:48 AM
To: MapGuide Users Mail List
Subject: [mapguide-users] Change xml files using the mapguide viewer API or mapguide web API

Hi,

It is possible using the MapGuide Viewer API Reference or the MapGuide Web API reference to change xml files that are located in the mapguide resource repository ?

For example we have in the Samples that are provided from the MapGuide Open Source site in Sheboygan, Library://Samples/Sheboygan/Layouts/SheboyganMap.PrintLayout which is a xml file.

 I want the user to have control about what informations are displayed on the map when he want's to print it, like don't show the legend, show the scaleBar....

I use as a guide the Plot as DWF task.

Thanks.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapguide-users/attachments/20090505/75dc7380/attachment.html


More information about the mapguide-users mailing list