You are on page 1of 1

# module for excel funtions

import xlrd
path = r'C:\Users\Richa Jha\OneDrive\Desktop\Student.xls'
# to open excel file
excel = xlrd.open_workbook_xls(path)
# to open sheet1
sheet = excel.sheet_by_index(0)
#print(sheet)
#print(sheet.nrows)
#print(sheet.ncols)
#print(sheet.row(1))
#print(sheet.col(1))

for row in range(sheet.nrows-1):


for col in range(sheet.ncols):
print(sheet.cell(row+1,col))

You might also like