[mapguide-users] buffer feature create. around added point.

Walt Welton-Lair walt.welton-lair at autodesk.com
Mon Jan 15 06:07:18 EST 2007

A layer will be excluded from buffering if either one of these applies:

1) the map coordinate system is non-arbitrary and the layer coordinate
system is arbitrary, or vice-versa
2) the layer and map coordinate systems are both arbitrary but have
different units

The layer's coordinate system comes from the feature source.  If your
feature source CS is non-arbitrary then you'll need to set a
non-arbitrary CS on the map to make this work.  Both MapGuide Studio and
Web Studio let you do this.


-----Original Message-----
From: mapguide-users-bounces at lists.osgeo.org
[mailto:mapguide-users-bounces at lists.osgeo.org] On Behalf Of Maciej
Sent: Monday, January 15, 2007 11:49 AM
To: mapguide-users at lists.osgeo.org
Subject: [mapguide-users] buffer feature create. around added point.


I add some points to map  (code in PHP)
When point is created i want to create a buffer around this point...when

i make it i get this error.

--start error message---
1 layers were excluded from buffer computation because their coordinate 
systems are incompatible with the coordinate system of the map, or 
because they have no coordinate system at all
--end error message---

so where can i set valid coordinate system? My map use
- *XY-M* (Arbitrary X-Y Coordinates (Meters))-.

//Creating the point
// $x , $y come from database
$geometryFactory = new MgGeometryFactory();
$coordinate = $geometryFactory->CreateCoordinateXY($x,$y);
$point = $geometryFactory->CreatePoint($coordinate);

//Define a property collection

$geometryReaderWriter = new MgAgfReaderWriter();
$properties = new MgPropertyCollection();
$properties->Add(new MgInt32Property('Id_obiektu',''.$id.''));
$properties->Add(new MgStringProperty('Typ',''.$typ_obiektu.''));
$properties->Add(new MgGeometryProperty('SHPGEOM', 

//Create an insert command for this property.

$parcelMarkerCommands->Add(new MgInsertFeatures('Obiekty',

if ($parcelMarkerCommands->GetCount() > 0)
$parcelMarkerCommands, false);


          $sessionIdName = "Session:$mgSessionId//gdansk2.Map";
          $sessionResourceID = new MgResourceIdentifier($sessionIdName);
          $map->Save($resourceService, $sessionResourceID);
          $mapUpdated = true;



mapguide-users mailing list
mapguide-users at lists.osgeo.org

More information about the mapguide-users mailing list