资源简介

C#2010 和ArcGIS Engine 10.0写的,直接应该是可以运行的,如果不是,配置相应的事件的话也是没有问题的。其实很简单,有需要的看看吧!

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace 动态点
{
    public partial class Form1 : Form
    {
        ESRI.ArcGIS.Geometry.IPointCollection ptCol;
        int i;
        int j;
        ESRI.ArcGIS.Carto.IElement pele;


        public Form1()
        {
            InitializeComponent();
        }
        private void Form1_FormClosing(object sender FormClosingEventArgs e)
        {
            ESRI.ArcGIS.Carto.IGraphicsContainer pCon = axMapControl1.Map as ESRI.ArcGIS.Carto.IGraphicsContainer;
            pCon.DeleteAllElements();
        }

        private void Form1_Load(object sender EventArgs e)
        {
            ESRI.ArcGIS.Carto.IFeaturelayer player = axMapControl1.Map.get_layer(0) as ESRI.ArcGIS.Carto.IFeaturelayer;
            ESRI.ArcGIS.Geodatabase.IFeatureCursor pCursor = player.Search(nullfalse);
            ESRI.ArcGIS.Geodatabase.IFeature pFeature = pCursor.NextFeature();
            while (pFeature != null)
            {
                ESRI.ArcGIS.Geometry.IGeometry pGeo = pFeature.Shape;
                ESRI.ArcGIS.Geometry.IConstructMultipoint pConPt = new ESRI.ArcGIS.Geometry.MultipointClass();
                pConPt.ConstructDivideEqual(pGeo as ESRI.ArcGIS.Geometry.ICurve 10);
                ptCol = pConPt as ESRI.ArcGIS.Geometry.IPointCollection;
                pFeature = pCursor.NextFeature();
            }
        }

        private void timer1_Tick(object sender EventArgs e)
        {
            ESRI.ArcGIS.Geometry.IPoint pPt;
            if (i > ptCol.PointCount - 1)
                i = 0;
            j = i;
            pPt = ptCol.get_Point(j);
            ESRI.ArcGIS.Carto.IGraphicsContainer pCon = axMapControl1.Map as ESRI.ArcGIS.Carto.IGraphicsContainer;
            ESRI.ArcGIS.Geometry.ITopologicalOperator pTop = pPt as ESRI.ArcGIS.Geometry.ITopologicalOperator;
            ESRI.ArcGIS.Geometry.IGeometry pGeo = pTop.Buffer(2);

            ESRI.ArcGIS.Carto.IPolygonElement pPolygonElement = new ESRI.ArcGIS.Carto.PolygonElementClass();
            pele = pPolygonElement as ESRI.ArcGIS.Carto.IElement;
            pCon.AddElement(pele 0);
            pCon.Reset();
            pele.Geometry = pGeo;
            pCon.UpdateElement(pele);
            i = i + 1;
            axMapControl1.ActiveView.PartialRefresh(ESRI.ArcGIS.Carto.esriViewDrawPhase.esriViewGraphics null null);
            axMapControl1.ActiveView.ScreenDisplay.UpdateWindow();
            if (i == 12)
            {
                pCon.DeleteAllElements();
            }
            axMapControl1.ActiveView.PartialRefresh(ESRI.ArcGIS.Carto.esriViewDrawPhase.esriViewGraphics null null);
            axMapControl1.ActiveView.ScreenDisplay.UpdateWindow();
        }
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件      17408  2013-08-23 10:27  动态点\动态点\bin\Debug\动态点.exe

     文件      24064  2013-08-23 10:27  动态点\动态点\bin\Debug\动态点.pdb

     文件      11608  2013-08-24 15:09  动态点\动态点\bin\Debug\动态点.vshost.exe

     文件        490  2010-03-17 22:39  动态点\动态点\bin\Debug\动态点.vshost.exe.manifest

     文件       2956  2013-08-24 15:16  动态点\动态点\Form1.cs

     文件       5121  2013-08-23 10:18  动态点\动态点\Form1.Designer.cs

     文件      15387  2013-08-23 10:18  动态点\动态点\Form1.resx

     文件     117634  2013-08-23 10:00  动态点\动态点\obj\x86\Debug\DesignTimeResolveAssemblyReferences.cache

     文件       7058  2013-08-23 10:27  动态点\动态点\obj\x86\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件       2890  2013-08-23 10:18  动态点\动态点\obj\x86\Debug\GenerateResource-ResGen.read.1.tlog

     文件        386  2013-08-23 10:18  动态点\动态点\obj\x86\Debug\GenerateResource-ResGen.write.1.tlog

     文件        651  2013-08-24 15:09  动态点\动态点\obj\x86\Debug\动态点.csproj.FileListAbsolute.txt

     文件      17408  2013-08-23 10:27  动态点\动态点\obj\x86\Debug\动态点.exe

     文件       6450  2013-08-23 10:18  动态点\动态点\obj\x86\Debug\动态点.Form1.resources

     文件      24064  2013-08-23 10:27  动态点\动态点\obj\x86\Debug\动态点.pdb

     文件        180  2013-08-23 10:10  动态点\动态点\obj\x86\Debug\动态点.Properties.Resources.resources

     文件        568  2013-08-23 10:05  动态点\动态点\Program.cs

     文件       1350  2013-08-23 09:59  动态点\动态点\Properties\AssemblyInfo.cs

     文件       2869  2013-08-23 09:59  动态点\动态点\Properties\Resources.Designer.cs

     文件       5612  2013-08-23 09:59  动态点\动态点\Properties\Resources.resx

     文件       1095  2013-08-23 09:59  动态点\动态点\Properties\Settings.Designer.cs

     文件        249  2013-08-23 09:59  动态点\动态点\Properties\Settings.settings

     文件       5881  2013-08-23 10:10  动态点\动态点\动态点.csproj

     文件        869  2013-08-23 09:59  动态点\动态点.sln

    ..A..H.     21504  2013-08-24 15:17  动态点\动态点.suo

     目录          0  2013-08-23 09:59  动态点\动态点\obj\x86\Debug\TempPE

     目录          0  2013-08-23 10:27  动态点\动态点\obj\x86\Debug

     目录          0  2013-08-23 10:10  动态点\动态点\bin\Debug

     目录          0  2013-08-23 09:59  动态点\动态点\obj\x86

     目录          0  2013-08-23 09:59  动态点\动态点\bin

............此处省略7个文件信息

评论

共有 条评论