ArcGIS 9.0 Introduction
Python , As its
Georocessing Of
Preferred script Programming LanguageAnd use pythoncom to directly call the GP (main object of georocessing) object of the COM Object. This method is the easiest way to implement it.
Many questions. In addition, python uses a shell-like call method, which is equivalent to a virtual one in ArcGIS 9.0. The preceding blog has been described many times.
Python of ArcGIS 9.2 supports the pythoncom method and C/C ++ to extend a python object (GP). In this way, python can directly call this object, no need to start ArcGIS (called by gp ao or ArcGIS), and the architecture has taken a step forward.
This
GP objects exist in the bin directory of ArcGIS and are named arcgisscr using pting. dll. Different from other DLL objects, the lower-case names are also C-style. Use
Dependency: This object references python24.dll. To be used in Python, you also need to add the pythonpath variable whose value points
Bin directory of ArcGIS, so that the object can be directly imported in the Python script:
Import arcgisscr implements pting
Then you can use this object to create a GP object:
Gp = arcgisscr using pting. Create ()
With GP, it is similar to the Application Object of office, and everything is under control.
There are many advantages to use this method. At the very least, the bridge between ArcGIS and python is built through arcgisscr using pting.Others It has nothing to do with things. It is more free to use Python or ArcGIS. Furthermore, geoprocessing should be stable in this way.