Skip to main content
improved formatting
Source Link
tinlyx
  • 11.2k
  • 18
  • 76
  • 127

import arcpy import os,sys

saveFeatureFold = 'F:\data\data.gdb\myData\'#you must create the gdb first and define the project you like featureFold = 'F:\dealWithData\ for file in os.listdir(featureFold ): if file.endswith('.shp'): fileName = featureFold +file saveName = saveFeatureFold +file arcpy.CopyFeatures_management(fileName,saveName )#so the project is you want to be

import arcpy
import os,sys

saveFeatureFold = 'F:\\data\\data.gdb\\myData\\'#you must create the gdb first and define the project you like
featureFold = 'F:\\dealWithData\\
for file in os.listdir(featureFold ):
    if file.endswith('.shp'):
        fileName = featureFold +file
        saveName = saveFeatureFold +file
        arcpy.CopyFeatures_management(fileName,saveName )#so the project is you want to be

import arcpy import os,sys

saveFeatureFold = 'F:\data\data.gdb\myData\'#you must create the gdb first and define the project you like featureFold = 'F:\dealWithData\ for file in os.listdir(featureFold ): if file.endswith('.shp'): fileName = featureFold +file saveName = saveFeatureFold +file arcpy.CopyFeatures_management(fileName,saveName )#so the project is you want to be

import arcpy
import os,sys

saveFeatureFold = 'F:\\data\\data.gdb\\myData\\'#you must create the gdb first and define the project you like
featureFold = 'F:\\dealWithData\\
for file in os.listdir(featureFold ):
    if file.endswith('.shp'):
        fileName = featureFold +file
        saveName = saveFeatureFold +file
        arcpy.CopyFeatures_management(fileName,saveName )#so the project is you want to be
Source Link

import arcpy import os,sys

saveFeatureFold = 'F:\data\data.gdb\myData\'#you must create the gdb first and define the project you like featureFold = 'F:\dealWithData\ for file in os.listdir(featureFold ): if file.endswith('.shp'): fileName = featureFold +file saveName = saveFeatureFold +file arcpy.CopyFeatures_management(fileName,saveName )#so the project is you want to be