Quantcast
Channel: Forums - Python
Viewing all articles
Browse latest Browse all 2485

Python or Model Builder Solution to write file names in Excel

$
0
0
Hello Everyone,

I am trying to list all photo name in excel column under header “PhotoName”. Currently I am using following code to get list of file names which works fine

import arcpy
from arcpy import env

# Set the current workspace
#
env.workspace = "S:\GIS\GIS Transfer\MichaelS_TrancheCSiteselectionReportFigures_20130322"

# Get a list of ESRI GRIDs from the workspace and print
#
rasterList = arcpy.ListRasters("*", "JPG")
for raster in rasterList:
print rasterList

But I would like to know code for next step which is to write in excel. Actually I want to use this table in model builder to perform join operation.

Can anyone please help regarding code and how to use that in model builder.

Thanks in advance

Viewing all articles
Browse latest Browse all 2485

Trending Articles