我有一个加密的 excel 文件,我需要与我知道如何使用这种方法读取数据
import io
import pandas as pd
import msoffcrypto
password= 'something'
decrypted_file = io.BytesIO()
with open(path_to_excel, "rb") as file:
excel_file = msoffcrypto.OfficeFile(file)
excel_file.load_key(password)
excel_file.decrypt(decrypted_file)
return decrypted_file
如何读取数据:From password-protected Excel file to pandas DataFrame
现在我的问题是如何写回这样的文件?
本站系公益性非盈利分享网址,本文来自用户投稿,不代表码文网立场,如若转载,请注明出处
评论列表(7条)