ExecuteError

この ArcGIS 3.1 ドキュメントはアーカイブされており、今後更新されません。 コンテンツとリンクが古い場合があります。 最新のドキュメントをご参照ください

サマリー

The ExecuteError exception class is raised whenever a geoprocessing tool encounters an error.

コードのサンプル

ExecuteError exception example

The ExecuteError class is used below to specifically handle any geoprocessing tool errors that result from CopyFeatures.

import arcpy

in_features = "c:/base/transport.gdb/roads"

try:
    # Note: CopyFeatures will always fail if the input and output are
    # the same feature class
    arcpy.CopyFeatures_management(in_features, in_features)

except arcpy.ExecuteError:
    print(arcpy.GetMessages())

関連トピック