import  arcgisscripting

import  string;

gp = arcgisscripting.create(9.3);

##多少个工具箱

toolboxes = gp.listToolboxes();

for toolbox in toolboxes:

    #截取工具箱的别名

    first = toolbox.index("("); ##第一个'('的索引值

    end = toolbox.index(")")    ##最后一个')'的索引值

    toolboxAlias = toolbox[first+1:end]; ##工具箱的别名

    gp.AddMessage(toolboxAlias);

    i = 0;

    tools = gp.listTools();

    for tool in tools:

        f =  tool.index("_"); ##"_"的索引值

        alias = tool[f+1:];

        if alias == toolboxAlias:

            gp.AddMessage( tool);

            i=i+1;

    gp.AddMessage(  "====="+toolbox+"'s count:"+str(i));

gp.AddMessage( "the tool count:"+str( len(tools)));

gp.AddMessage(  "the toolbox count:"+str(len(toolboxes)));

  

最新文章

  1. 使用adagio包解决背包问题
  2. C++程序内存泄漏检测方法
  3. Eclipse下Android开发错误之Unable to execute dex: java.nio.BufferOverflowException. Check the Eclipse log for stack trace
  4. listview java.lang.ArrayIndexOutOfBoundsException:
  5. [原]常用sqlserver数据库使用sql语句
  6. 【Java设计模式】单例模式
  7. hdu 5206 Four Inages Strategy
  8. JAXB - Calling marshal
  9. 温故而知新 C++ 类型转换
  10. centos6.5 升级python 到 python 2.7.11 安装 pip
  11. Snail’s trouble
  12. ajax_get/post_两级联动
  13. 通过url获取相应的location信息
  14. api-gateway实践(15)3.6JL分支和3.7并行改造需求
  15. UNIX环境高级编程——创建孤儿进程
  16. emWin仪表界面设计,含uCOS-III和FreeRTOS两个版本
  17. 四、Mysql主从同步
  18. Multi-Fiber Networks for Video Recognition (MFNet)
  19. Redis学习系列五Set(集合)
  20. hdu5242 Game (贪心+dfs序)

热门文章

  1. centos 6.9安装python 3.6
  2. scrapy 基础使用以及错误方案
  3. SpringBoot Controller接收参数的几种常用方
  4. BZOJ3393 [Usaco2009 Jan]Laserphones 激光通讯 BFS
  5. F(x) 数位dp
  6. 043 关于 loadrunner 返回 http 500 错误解决思路
  7. IDEA添加源码包
  8. html-背景图片
  9. create-react-app项目添加less配置
  10. position的定义