laptop and a wrench

Bug

ListFeatureClasses(), ListTables() and ListDatasets() methods will not work in ArcToolbox as a script tool, but work fine in PythonWin.These methods were defected with shapefiles but not with personal geodatabse and file geodatabase.

Last Published: August 25, 2014 No Product Found
Bug ID Number NIM011091
SubmittedAugust 20, 2007
Last ModifiedJune 5, 2024
Applies toNo Product Found
Version found9.2
Version Fixed9.3
StatusFixed

Workaround

1) Convert all shapefiles from a folder to one personal geodatabase or file geodatabase.OR2) Use native a py module method to list shapefiles from a directory. The following is an example of how you could use the glob module to build a list of all shapefiles in a given directory. #############################import sys, string, os, glob, timegp = arcgisscripting.create()root = r"C:\Incidents\Active" # one specific folderfile_list = []for folder in glob.glob(root): for file in glob.glob(folder + '/*.shp'): file_list.append(file)x = 0while x < len(file_list): print file_list[x] x+=1############################

Steps to Reproduce

Bug ID: NIM011091

Software:

  • No Product Found

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options