首页 > 编程语言 > 详细

[python] xlrd

时间:2016-05-02 07:05:37      阅读:291      评论:0      收藏:0      [点我收藏+]

0.xlrd introduce 

Library for developers to extract data from Microsoft Excel (tm) spreadsheet files

1. install xlrd

2. use xlrd in python

技术分享
1 import xlrd
2 
3 book = xlrd.open_workbook(f)
4 sheet = book.sheet_by_index(0)  
5 sheet.cell(ROW_NO, COLUM_NO).value  
View Code

line 1: import xlrd module

line 3: open a xlsx file whose name is f

line4: open a sheet whose number is 0

line 5: get a specific value which is in (ROW_NO, COLUM_NO)

[python] xlrd

原文:http://www.cnblogs.com/sarah-zhang/p/5451835.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!