AnsweredAssumed Answered

List Feature Classes within Subfolders using Python

Question asked by tjansen84 on Jan 6, 2011
Latest reply on Nov 13, 2014 by JBigos-esristaff
I'm trying to get a list of feature classes in a folder and it's subfolders.  Below is a script that gets just the folder specified.  Any help on how to loop through the subfolders is appreciated.

import arcpy
from arcpy import env
import os
# Set the workspace for the ListFeatureClass function
env.workspace = "C:/Data"
# Use the ListFeatureClasses function to return a list
fcList = arcpy.ListFeatureClasses()
print fcList