mapxtreme 中将图元放在指定的位置

 
         public   void  SetFeatureLocation(Feature fr,  double  x, double  y)
        ...
{
            
if(fr!=null)
            ...
{
                DPoint lastP
=fr.Geometry.Centroid;

                
double stepX=x-lastP.x;
                
double stepY=y-lastP.y;
                    
                fr.Geometry.GeometryEditor.OffsetByXY(stepX,stepY,DistanceUnit.Degree,DistanceType.Spherical);
                fr.Geometry.EditingComplete();
                fr.Update();
            }

        }

你可能感兴趣的:(null)