I am trying to read multiple tabs in spreadsheet to different dataframes and once all tabs with data are over the program should stop.
For first part I am looking to do something like
xls = pd.ExcelFile('Unique.xlsx')
for i in range(1,n): # n should be number of tabs with data
try:
df_Sector(i)=xls.parse('Sheet'+i) # df_Sector(i) has to be dataframe
except:
pass
I want the program to stop once all tabs with data are read