摘要: import sys reload(sys) sys.setdefaultencoding('utf8') import xlrd import xlwt book = xlrd.open_workbook('C:/Users/13717/Desktop/sg.xls') sheet = book.sheet_by_index(0) book1 = xlwt.Workbook() #创... 阅读全文
posted @ 2018-09-10 12:35 破晓e 阅读(286) 评论(0) 推荐(0) 编辑
摘要: import xlrd book = xlrd.open_workbook(file_path)#打开文件 sheet = book.sheet_by_index(0) #获取第一个工作簿 print sheet.nrows,sheet.ncols #打印行数,列数 for i in range(sheet.nrows): print sheet.row(i)[0].value ... 阅读全文
posted @ 2018-09-10 11:53 破晓e 阅读(233) 评论(0) 推荐(0) 编辑