I am trying to create a script with arcpy that reads several excel sheets within an .xlsx file, then returns the values of the specified cells in the sheets into an attribute table. When I run the tool, the error code returned states that No such file or directory exists to my specified file. A snippet of my code is as follows:
[...]
try:
file = arcpy.GetParameterAsText(0)
outputFC = arcpy.GetParameterAsText(1)
# ==========================================================================
# read how many sheets are in file
df = pd.read_excel(file)
# read number of columns and rows
columns = pd.read_excel(file, usecols='A,B,C,D,E,F,G,H')
while df['value'].sum > 0:
for rows in columns.iterrows:
GenInfo = df.iloc[13]
ConAssess = df.iloc[19]
Comments = df.iloc[24:33]
[...]