Last active
February 1, 2017 02:59
-
-
Save m5knt/05ef872859611384a41a55cd26ad76a1 to your computer and use it in GitHub Desktop.
python で excel をダンプ
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import openpyxl | |
book = openpyxl.load_workbook(filename='a.xlsx', | |
read_only=True, | |
use_iterators=True, | |
data_only=True) | |
sheet = book.get_sheet_by_name('Sheet1') | |
datas = [t for t in sheet.iter_rows()] | |
for rows in datas: | |
print([type(cell.value) for cell in rows]) | |
print([cell.value for cell in rows]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment