Bug
Bug ID Number | NIM000093 |
---|---|
Submitted | October 18, 2005 |
Last Modified | June 5, 2024 |
Applies to | No Product Found |
Version found | 9.1 |
Status | Will Not Be Addressed |
Code:
import win32com.client, sys, string
GP = win32com.client.Dispatch("esriGeoprocessing.GPDispatch.1")
GP.SetParameterAsText(0,"100")
Code:
# ---------------------------------------------------------------------------
# model_to_script.py
# Created on: Fri Oct 14 2005 11:36:54 AM
# (generated by ArcGIS/ModelBuilder)
# ---------------------------------------------------------------------------
# Import system modules
import sys, string, os, win32com.client
# Create the Geoprocessor object
gp = win32com.client.Dispatch("esriGeoprocessing.GpDispatch.1")
gp.overwriteoutput = 1
# Set the necessary product code
gp.SetProduct("ArcEditor")
# Load required toolboxes...
gp.AddToolbox("C:/Program Files/ArcGIS/ArcToolbox/Toolboxes/Data Management Tools.tbx")
gp.AddToolbox("C:/Temp/MyToolBox.tbx")
# Local variables...
my_output = "100"
rivers_shp = "C:\\ESRI\\ESRIDATA\\MEXICO\\rivers.shp"
Output_Feature_Class = "C:\\ESRI\\ESRIDATA\\MEXICO\\rivers_SimplifyLine.shp"
Output_Point_Feature_Class = "C:\\ESRI\\ESRIDATA\\MEXICO\\rivers_SimplifyLine_Pnt.shp"
# Process: custom_gp_tool...
gp.toolbox = "C:/Temp/MyToolBox.tbx"
gp.custom_gp_tool()
# Process: Simplify Line...
gp.SimplifyLine_management(rivers_shp, Output_Feature_Class, "POINT_REMOVE", my_output,
"FLAG_ERRORS", "KEEP_COLLAPSED_POINTS")
Code:
gp.custom_gp_tool()
Code:
my_output = gp.custom_gp_tool()
Bug ID: NIM000093
Software:
Get help from ArcGIS experts
Download the Esri Support App