解决方案 »

  1.   

    画点
    IPoint pt;
    pt = axMapControl1.ToMapPoint(e.x, e.y);
    IMarkerElement pMarkerElement;
    pMarkerElement = new MarkerElementClass();
    IElement pElement;
    pElement = pMarkerElement as IElement;
    pElement.Geometry = pt;
    pGraphicsContainer = pMap as IGraphicsContainer;
    pGraphicsContainer.AddElement((IElement)pMarkerElement, 0);
    pActiveView.Refresh();
    画线IGeometry polyline;
    polyline = axMapControl1.TrackLine();
    ILineElement pLineElement;
    pLineElement = new LineElementClass();
    IElement pElement;
    pElement = pLineElement as IElement;
    pElement.Geometry = polyline;
    pGraphicsContainer = pMap as IGraphicsContainer;
    pGraphicsContainer.AddElement((IElement)pLineElement, 0);
    pActiveView.Refresh();画面IGeometry Polygon;
    Polygon = axMapControl1.TrackPolygon();
    IPolygonElement PolygonElement;
    PolygonElement = new PolygonElementClass();
    IElement pElement;
    pElement = PolygonElement as IElement;
    pElement.Geometry = Polygon;
    pGraphicsContainer = pMap as IGraphicsContainer;
    pGraphicsContainer.AddElement((IElement)PolygonElement, 0);
    pActiveView.Refresh();
      

  2.   

    用这个无法嵌入互操作类型“ESRI.ArcGIS.Carto.MarkerElementClass”。请改用适用的接口。 该如何解决啊?
      

  3.   

    LineElementClass这个也是一样的问题
      

  4.   

    用这个无法嵌入互操作类型“ESRI.ArcGIS.Carto.MarkerElementClass”。请改用适用的接口。 该如何解决啊?解决方案如下:
    http://blog.csdn.net/ldl22847/article/details/7275410
      

  5.   

    要实现类似于button一样的点击事件,点击后就加载在代码中绘制的图形。或者在运行程序是就加载。该如何实现呢?arcgis engine什么事件符合这种要求呢?
      

  6.   

    已经基本实现我所需要的东西了 谢谢taomanman的帮助。非常感谢
      

  7.   

    用这个无法嵌入互操作类型“ESRI.ArcGIS.Carto.MarkerElementClass”。请改用适用的接口。 该如何解决啊?解决方案如下:
    http://blog.csdn.net/ldl22847/article/details/7275410
    绘制多个点并连接其中两个或多个点该如何改写呢?  我绘制的点虽然写了两个点代码,但是只生成一个点。该如何修改呢?