iegbulefu

Python Script to

Discussion created by iegbulefu on Aug 8, 2012
Latest reply on Aug 21, 2012 by iegbulefu
Hi everyone,
I need a script that can can  iterate through  folders that contains all my CAD files and authomatically convert each CAD file to a feadture dataset and store them in a specified geodatabase.

I already created a script that is able to pick up a specified CAD file rum the given folder and converts it to a geodatabase with feature dataset, but i need to iterate through the folder to convert all the other files to feature database


>>> import arcpy
... from arcpy import env
... env.workspace = "C:/data1"
... input_cad_dataset = "C:/CADdata/94a88W01.dwg"
... output_gdb_path = "c:/data/cadfile.gdb"
... output_dataset_name = "cad9488"
... reference_scale = "500"
... spatial_reference = "NAD_1983_10TM115"
... arcpy.CADToGeodatabase_conversion(input_cad_dataset, output_gdb_path, output_dataset_name, reference_scale)
... reference_scale = "2500"
... arcpy.CADToGeodatabase_conversion(input_cad_dataset, output_gdb_path, output_dataset_name, reference_scale)
... 

Outcomes