Executing a system tool

The following code example shows the execution of the Buffer tool from the Analysis tools toolbox. The required parameters for the tool are defined. In this case, strings are used to define the input, output, and buffer distance properties so the call to the tool is easier to read.
[C#]

  1. // Add references to esriSystem for licensing and IVariantArray.
  2. using ESRI.ArcGIS.esriSystem;
  3. // Add a reference to the geoprocessing namespace.
  4. using ESRI.ArcGIS.Geoprocessing;
  5.  
  6. private static void RunBuffer()
  7. {
  8. // Create the geoprocessor.
  9. IGeoProcessor2 gp = new GeoProcessorClass();
  10.  
  11. // Create an IVariantArray to hold the parameter values.
  12. IVariantArray parameters = new VarArrayClass();
  13.  
  14. // Populate the variant array with parameter values.
  15. parameters.Add(@"D:\St_Johns\data.mdb\roads");
  16. parameters.Add(@"D:\St_Johns\data.mdb\roads_Buffer");
  17. parameters.Add("1000 Meters");
  18.  
  19. // Execute the tool.
  20. gp.Execute("Buffer_analysis", parameters, null);
  21. }

Executing a system tool的更多相关文章

  1. GP中Geoprocessor.Execute(string name, IVariantArray parameters, ITrackCancel trackCancel)

    在做一个项目的过程中,发现GP运算方法 Execute(string name, IVariantArray parameters, ITrackCancel trackCancel) 与Execut ...

  2. 在执行一行代码之前CLR做的68件事[The 68 things the CLR does before executing a single line of your code]

    待翻译,原文地址:http://mattwarren.org/2017/02/07/The-68-things-the-CLR-does-before-executing-a-single-line- ...

  3. apk反编译(6)ProGuard 工具 android studio版官方教程[作用,配置,解混淆,优化示例]

    ProGuard In this document Enabling ProGuard (Gradle Builds) Configuring ProGuard Examples Decoding O ...

  4. troubleshooting tools in JDK 7--转载

    This chapter describes in detail the troubleshooting tools that are available in JDK 7. In addition, ...

  5. 《CS:APP》 chapter 8 Exceptional Control Flow 注意事项

    Exceptional Control Flow The program counter assumes a sequence of values                            ...

  6. SAP NOTE 1999997 - FAQ: SAP HANA Memory

    Symptom You have questions related to the SAP HANA memory. You experience a high memory utilization ...

  7. PAN-OS 6.1 Open Source Software (OSS) Listing

    https://www.paloaltonetworks.com/documentation/oss-listings/oss-listings/pan-os-oss-listings/pan-os- ...

  8. Automated Memory Analysis

    catalogue . 静态分析.动态分析.内存镜像分析对比 . Memory Analysis Approach . volatility: An advanced memory forensics ...

  9. 深入研究java.lang.Runtime类

    一.概述      Runtime类封装了运行时的环境.每个 Java 应用程序都有一个 Runtime 类实例,使应用程序能够与其运行的环境相连接.      一般不能实例化一个Runtime对象, ...

随机推荐

  1. 看看PHP迭代器的内部执行过程

    class myIterator implements Iterator { private $position = 0; private $array = array( "first_el ...

  2. Django-manage.py

    一.manage.py命令选项 manage.py是每个Django项目中自动生成的一个用于管理项目的脚本文件,需要通过python命令执行.manage.py接受的是Django提供的内置命令. 内 ...

  3. 前端网页进度Loading

    loading随处可见,比如一个app经常会有下拉刷新,上拉加载的功能,在刷新和加载的过程中为了让用户感知到 load 的过程,我们会使用一些过渡动画来表达.最常见的比如“转圈圈”,“省略号”等等. ...

  4. 使用BEEGO建立一个基本的API框架

    用BEE API命令生成框架. 然后自行更改MODELS,加入MYSQL支持ORM. 然后,自定义了字段的对应,表的名称等. 参考URL: http://www.cnblogs.com/studyzy ...

  5. IEEEXtreme 10.0 - Painter's Dilemma

    这是 meelo 原创的 IEEEXtreme极限编程比赛题解 Xtreme 10.0 - Painter's Dilemma 题目来源 第10届IEEE极限编程大赛 https://www.hack ...

  6. PHP实现插入排序

    插入排序思想: 插入排序(Insertion Sort)的算法描述是一种简单直观的排序算法. 它的工作原理是通过构建有序序列,对于未排序数据,在已排序序列中从后向前扫描, 找到相应位置并插入.插入排序 ...

  7. Python并发编程-多进程socketserver简易版

    普通版的socketserver #server.py import socket sk = socket.socket() sk.bind(('127.0.0.1',8080))#建立连接 sk.l ...

  8. 光线求交-面、三角形、球 (Ray intersection)

    光线求交 光线定义:position \(a(t)\) = \(o\) + \(t\vec{d}\); 球定义: center p, radius r; 平面定义:normal \(\vec{n}\) ...

  9. Scrapy实战篇(八)之简书用户信息全站抓取

    相对于知乎而言,简书的用户信息并没有那么详细,知乎提供了包括学习,工作等在内的一系列用户信息接口,但是简书就没有那么慷慨了.但是即便如此,我们也试图抓取一些基本信息,进行简单地细分析,至少可以看一下, ...

  10. 【WIN10】Storyboard動畫板

    源碼下載:http://yunpan.cn/cFJR5zcMNtBq6  访问密码 ac7a 使用Storyboard可以實現動畫效果. 1.仿照WINDOWS系統安裝時的等待畫面,不停更換背景顏色 ...