I am trying to create a new script with a hard-coded geodatabase filename, that lists the feature classes it contains to the console. I know there are several ways to do this, but I decided to to use ListFeatureClasses function.
I got the following sample code from ArcGIS website, but I do not know what changes I need to make in order for it to work. I barely started studying Python, so I know very basic stuff, but I would like to get help with this.
import os import arcpy # Set the workspace for ListFeatureClasses arcpy.env.workspace = "c:/base" # Use the ListFeatureClasses function to return a list of # shapefiles. featureclasses = arcpy.ListFeatureClasses() # Copy shapefiles to a file geodatabase for fc in featureclasses: arcpy.CopyFeatures_management( fc, os.path.join("c:/base/output.gdb", os.path.splitext(fc)))