from openpyxl import load_workbook from openpyxl.styles import PatternFill def dum(): wb = load_workbook( […] 2.8 查询excel重复数据
from openpyxl import Workbook, load_workbook from datetime import date def create_data(): wb = Workbook() sh […] 2.7 统计加班时间
from openpyxl import load_workbook from openpyxl.styles import PatternFill wb = load_workbook(filename=r […] 2.6 隔行变色
from openpyxl import load_workbook,Workbook def create_excel(): wb = load_workbook('./办公自动化/files/工资表.x […] 2.5 工资条案例
import os from openpyxl import Workbook, load_workbook import re import shutil def copy_data(): wb = Workboo […] 2.4 多个excel 合并到多个sheet
import os from openpyxl import Workbook, load_workbook import re import shutil def copy_data(): wb = Workboo […] 2.3 openpyxl 数据合并到一个sheet
import openpyxl from openpyxl import Workbook from openpyxl.chart import ( Reference, Series, AreaChart3D ) […] 2.2 openpyxl 3D图表
from openpyxl import Workbook,load_workbook from openpyxl.chart import BarChart, Series, Reference # wb = Wo […] 2.1 openpyxl 图表案例
# pip install openpyxl # 使用openpyxl from openpyxl.chart import Reference from openpyxl.chart import LineChar […] 2. openpyxl 处理表格
import xlrd from xlutils.copy import copy def get_data(): wb = xlrd.open_workbook('./办公自动化/files/orders […] 1.4 表格的数据拆分
import xlrd from xlutils.copy import copy def read_data(): wb = xlrd.open_workbook('./办公自动化/files/order […] 1.3 数据汇总案例
# pip install xlutils import xlrd import xlutils from xlutils.copy import copy # 打开excel read_book = xlrd.op […] 1.2 xlutils 表格编辑处理
# pip install xlrd import xlrd # 打开excel wb = xlrd.open_workbook('./办公自动化/files/电影.xls') # 选择sheet […] 1.1 xlrd 表格读取数据
# pip install xlwt import xlwt # xlwt只支持xls文件 # 创建一个excel wb = xlwt.Workbook() # 选择工作簿 sh = wb.add_sheet( […] 1. xlwt 创建表格写入数据
# shutil 模块是基于高级文件操作库 os 模块构建的,提供了更高级别的文件操作接口,使文件和目录的处理更加方便。 # 通过 shutil 模块,可以执行以下操作: # 复制文件和目录。 # 移动文件和目录。 […] 0. shutil 模块 操作文件