xlwings
安装和导入xlwings
- pip install xlwings -i https://
- import xlwings as xw
使用
import xlwings as xw
with xw.App() as app:
wb = app.books(r"文件路径") # type: xw.Book
sht = wb.sheets(1)
res = sht.range("a1").expend().value
import xlwings as xw
with xw.App() as app:
wb = app.books(r"文件路径") # type: xw.Book
sht = wb.sheets(1)
res = sht.range("a1").expend().value