随笔分类 -  Python

摘要: 阅读全文
posted @ 2022-07-01 20:01 MING5135 阅读(30) 评论(0) 推荐(0) 编辑
摘要:import os import openpyxl path = r"C:\Users\asuka\Desktop" os.chdir(path) # 修改工作路径 workbook = openpyxl.load_workbook('test.xlsx') # 返回一个workbook数据类型的值 阅读全文
posted @ 2022-05-31 22:18 MING5135 阅读(245) 评论(0) 推荐(0) 编辑
摘要:1 import os 2 3 def renameFile(): 4 try: 5 os.rename(srcFile,dstFile) 6 except Exception as e: 7 print(e) 8 print('rename file fail\r\n' + srcFile ) 9 阅读全文
posted @ 2022-05-30 22:51 MING5135 阅读(48) 评论(0) 推荐(0) 编辑
摘要:import pandas as pd import os import openpyxl from openpyxl import load_workbook # import xlrd # import xlwt # from xlutils.copy import copy jsonObj = 阅读全文
posted @ 2022-04-18 21:16 MING5135 阅读(59) 评论(0) 推荐(0) 编辑
摘要:import pandas as pd srcFile =B2CExcel a = "2C发票_2022040111" dstFile = srcFile.replace(a,${b2cCurrentdate},1); df = pd.read_excel(B2CExcel) write = pd. 阅读全文
posted @ 2022-04-18 21:08 MING5135 阅读(128) 评论(0) 推荐(0) 编辑
摘要:1 import pandas as pd 2 import os 3 import xlwt 4 5 # 提取invoiceHeadExcel1内数据 6 file11 = invoiceHeadExcel1 7 filePath11 = file11.replace("\\", "\\\\") 阅读全文
posted @ 2022-03-31 19:45 MING5135 阅读(556) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示