Exemplo n.º 1
0
        private bool AddPolygon(IPolygon polygon)
        {
            AddFeatureToLayer frmAFTL = new AddFeatureToLayer(axMapControl1.Map, polygon);

            frmAFTL.Show();
            if (frmAFTL.DialogResult == System.Windows.Forms.DialogResult.OK)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }
Exemplo n.º 2
0
        //以下三个函数是添加要素的主函数
        private bool AddPoint(double x, double y)
        {
            IPoint point = new PointClass();

            point.PutCoords(x, y);
            AddFeatureToLayer frmAFTL = new AddFeatureToLayer(axMapControl1.Map, point);

            frmAFTL.Show();
            if (frmAFTL.DialogResult == DialogResult.OK)
            {
                return(true);
            }
            else
            {
                return(false);
            }
        }