【问题标题】:How to loop through excel sheets in python file to calculate the values spread across the sheets?如何遍历 python 文件中的 excel 工作表来计算分布在工作表上的值?
【发布时间】:2021-10-31 08:40:26
【问题描述】:

我有一个包含 3 张工作表的 excel 文件,每张工作表在单元格 A1 中都有一组值。我将如何遍历工作表并计算值?

我是 python 新手,一直在努力寻找解决这个问题的方法。 谢谢

【问题讨论】:

标签: python excel pandas


【解决方案1】:

结帐this 代码#3,您可以在其中通过循环sheet = wb.sheet_by_index(x) 更新工作表并检索单元格值sheet.cell_value(0, 0)

【讨论】:

    猜你喜欢
    • 2020-04-05
    • 2019-09-25
    • 2020-12-07
    • 1970-01-01
    • 2018-11-29
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多