看板 Python 關於我們 聯絡資訊
Hi, 我目前有一excel文件 a.xls,想填值並保留設定到b.xls 我簡單測試如下 import xlrd from xlutils.copy import copy org_file = xlrd.open_workbook('C:\\a.xls',formatting_info=True) copy_file = copy(org_file) copy_file.save('C:\\b.xls') 執行完後,當我打開b.xls時,巨集沒了 我用openpyxl處理xlsx file沒這種問題,因為處理xls file才使用xlrd,xlwt,xlutils 請問是xlutils本身copy不支援巨集部分嗎? 請問有人了解/解決過此問題能幫解惑 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 111.251.178.12 (臺灣) ※ 文章網址: https://www.ptt.cc/bbs/Python/M.1622709203.A.EA9.html ※ 編輯: nienyun (111.251.178.12 臺灣), 06/03/2021 16:35:02
AndCycle: 對,你自己已經回答完了 06/03 17:48
nienyun: 好吧,謝謝 06/03 23:16