zoukankan      html  css  js  c++  java
  • 利用gp自己做的生成缓冲区的代码

    主要部分代码,参数来源略

                Geoprocessor gp = new Geoprocessor();
                gp.OverwriteOutput = true;
                ESRI.ArcGIS.AnalysisTools.Buffer pbuffer = new ESRI.ArcGIS.AnalysisTools.Buffer();
                pbuffer.in_features = pFeLayer;
                pbuffer.buffer_distance_or_field = Convert.ToString((this.textBox1.Text)) + " " + (string)this.comboBox2.Text;
                pbuffer.out_feature_class = this.textBox2.Text;
                gp.Execute(pbuffer, null);
                IFeatureLayer pFeatureLayer = new FeatureLayerClass();
                IWorkspaceFactory pWsF = new ShapefileWorkspaceFactoryClass();
                IFeatureWorkspace pFWs = (IFeatureWorkspace)pWsF.OpenFromFile(FilePath, 0);
                IFeatureClass pFeatureClass = pFWs.OpenFeatureClass(FileName);
                pFeatureLayer.FeatureClass = pFeatureClass;
                pFeatureLayer.Name = pFeatureClass.AliasName;
                prmForm.axMapControl1.AddLayer(pFeatureLayer);
                MessageBox.Show("缓冲完毕", "提示");
                prmForm.axMapControl1.ActiveView.PartialRefresh(esriViewDrawPhase.esriViewAll, null, null);

  • 相关阅读:
    POJ 3273 :Monthly Expense【二分+贪心】
    POJ 3104 Drying【二分】
    Codeforces Round #402 (Div. 2)
    PAT 天梯赛真题集
    PAT 乙级 (将剩下的做了)
    CCPC 2016-2017, Finals (慢慢做,慢慢更新)
    Spring注解开发
    SpringMVC+SSM框架
    Spring5 Framework(IOC+AOP+整合Mybatis事务)
    IDEA 使用小技巧
  • 原文地址:https://www.cnblogs.com/weihongli/p/2173832.html
Copyright © 2011-2022 走看看