# Calls a model called Test (with no parameters) in a toolbox with the Alias set to AUTO arcpy.Test_AUTO()
# Calls a model called Test (with 1 parameter) in a toolbox with the Alias set to AUTO arcpy.Test_AUTO(r"c:\temp\clipPoly.shp")
resObj = arcpy.Test_AUTO(r"c:\temp\clipPoly.shp") if resObj.status == 4: print "success!" else: print "failure "
The best practice is to assign an alias when first creating the toolbox rather than using ImportToolbox to assign a temporary one that will only be applicable in Python.
arcpy.ImportToolbox(r"x:\MB_Svenne\AutoRun.tbx", "TBX")
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.