import os,xlrdnumh=0.0for f in os.listdir('D:\\excel'): print "file:",f wb=xlrd.open_workbook(os.path.abspath(f)) table=wb.sheet_by_index(1) for r in range(table.nrows): numh=table.cell(r,0).value+numh print 'numh:',numh