【问题标题】:xlwings on mac os using api.autofill() dont work使用 api.autofill() 在 mac os 上的 xlwings 不起作用
【发布时间】:2020-03-26 07:20:24
【问题描述】:

我知道下面的代码适用于 Windows,但有人可以告诉我它在 Mac OS 上的工作原理吗?

import xlwings as xw
from xlwings.constants import AutoFillType

wb = xw.Book('Book1')
sheet = wb.sheets(1)
sheet.range('A2').api.AutoFill(sheet.range("A2:A10").api,
                               AutoFillType.xlFillDefault)

【问题讨论】:

    标签: python autofill xlwings


    【解决方案1】:

    问题解决了!

    import xlwings as xw
    from xlwings.constants import AutoFillType
    
    wb = xw.Book('euromillions.csv')
    ws = wb.sheets('euromillions')
    
    ws.range("A2").api.autofill(destination = ws.range("A2:A5").api, type = AutoFillType.xlFillDefault)
    

    【讨论】:

      猜你喜欢
      • 2012-05-14
      • 1970-01-01
      • 1970-01-01
      • 2017-11-05
      • 2015-01-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2023-03-22
      相关资源
      最近更新 更多