[mapguide-users] Saving a point to map permanently
sathishpsk9
sathishpsk9 at gmail.com
Tue Jun 9 08:17:26 EDT 2009
Hi saloua,
Thanks for reply .... but i what have you disscussed is not the
problem.... because i have taken co-ordinates from Digitized()
method......that might be beacuase of map ... bcoz i open it in session and
whatever i add to it are being stored in session only ....and when i refresh
the page session id changes ... so the changes i made not in current
sessions .....so any other way out or if possible send your code which does
this .......... i could analyze
my code of adding layerdefination which have created to add point to current
map goes like this
String layerDef = "Library:" + "//" + "ShapeFile" + "/" +
"lay1.LayerDefinition";
MgResourceIdentifier layerDefId = new
MgResourceIdentifier(layerDef);
resourceSrvc.SetResource(layerDefId, layerDefContent,
null);//layerdefContentis layerdefination which have created to add point
to current map
MgLayer myLayer = new MgLayer(layerDefId, resourceSrvc);
myLayer.SetName(myLayerName);
myLayer.SetVisible(true);
myLayer.SetLegendLabel("Point oF Interest ");
myLayer.SetDisplayInLegend(true);
myLayer.SetSelectable(true);
map.GetLayers().Insert(0, myLayer);
//map.GetLayers().Add(myLayer);
map.Save(resourceSrvc);
myLayer.ForceRefresh();
thanks & regards,
Satish
--
View this message in context: http://n2.nabble.com/Saving-a-point-to-map-permanently-tp3041754p3049093.html
Sent from the MapGuide Users mailing list archive at Nabble.com.
More information about the mapguide-users
mailing list