[mapguide-users] Saving map to session doesn't persist?
Jason Birch
Jason.Birch at nanaimo.ca
Fri Nov 17 13:22:55 EST 2006
This is what the code looks like now:
//Set up the map to be used in this service
$resourceID = new
MgResourceIdentifier('Library://Samples/Sheboygan/Maps/Sheboygan.MapDefi
nition');
//Create a connection to the map
$map = new MgMap();
$map->Create($resourceService,$resourceID,'Sheboygan');
//Save the map into the repository
$mapId = new MgResourceIdentifier("Session:$sessionId//Sheboygan.".
MgResourceType::MapDefinition);
$map->Save($resourceService, $mapId);
Now I'm getting the following error on the MgMap->Save :
Error: An exception occurred in the XML parser.
Details:An exception occurred in the XML parser. Exception occurred in
method MgResourceContentManager.ValidateDocument at line 586 in file
c:\build_tux_area\mgdev\server\src\services\resource\ResourceContentMana
ger.cpp
???
Is it possible that the MapDefinition in the Sheboygan sample is not
valid? But then it would have errored on the Load in Administrator.
Jason
-----Original Message-----
From: Tom Fukushima [mailto:tom.fukushima at autodesk.com]
Sent: Friday, November 17, 2006 09:26
To: users at mapguide.osgeo.org
Subject: RE: [mapguide-users] Saving map to session doesn't persist?
Hi Jason,
Where you are using MgResourceType::Map, try using
MgResourceType::MapDefinition instead.
Hope this solves the problem,
Tom
-----Original Message-----
From: Jason Birch [mailto:Jason.Birch at nanaimo.ca]
Sent: Friday, November 17, 2006 10:08 AM
To: users at mapguide.osgeo.org
Subject: [mapguide-users] Saving map to session doesn't persist?
I've attached an example that I think should save a MapDefinition to the
session repository, but a call to MapAgent to render the map comes up
with a MgResourceNotFoundException (I think).
Is there something that says that MapDefinitions need to be modified to
be persisted? Is there a typo in there somewhere?
Jason
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe at mapguide.osgeo.org
For additional commands, e-mail: users-help at mapguide.osgeo.org
More information about the Mapguide_users
mailing list