[mapguide-users] How to delete temporary layer from user session - or how to reload 1 added point whit definition in xml.

Maciej Skorczewski maciej.skorczewski at procad.pl
Tue Jan 23 08:46:18 EST 2007


Hi all!

My problem is strange so i write small 	introduction.
I make it whit  this steps.

-------
1 STEP. I Get points who are stored in database (user can add new points 
on map who after moderate are showed on map).

-------
2 STEP. I add point to map by use:


$geometryFactory = new MgGeometryFactory();
$coordinate = $geometryFactory->CreateCoordinateXY($x,$y);
$point = $geometryFactory->CreatePoint($coordinate);


...definition of points (symbols,x,y,image of object) are stored in XML 
file (who is loaded by

  function CreateParcelMarkerLayer($resourceService, 
$parcelMarkerDataResId, $sessionId))

one XML file is generate whit rules of each points who are stored in 
database.

-------
3 STEP. I add this points to map (execute my script)

so i get

a) layer is created- and added to layerpane - OK!
b) points are on the map - every have different icon and size.- OK!



BUT when i edit point i change it: (Rotation or X,Y - size in Meters)

THE PROBLEM IS HOW CAN I RELOAD ONLY ONE POINT WHO EDITED WAS?


What i make now;

1. i can delete this point
2. i add new point in this same place - BUT IT have this same definition 
of deleted point - so when i add changes (i generate new xml file whit 
definition of points) ex. it have another Rotation lebel... the new 
points have old gefinition



What can help me:

1. how to delete from curent user session layer whit ceated points - now 
i can only hidden only by

  $parcelMarkerLayer->SetDisplayInLegend(false);
  $parcelMarkerLayer->SetSelectable(false);

2. after dalete it - i must reload in again (whit new XML definition of 
each points) - it should by named this same.


Any sugestion?


Maciek



More information about the mapguide-users mailing list