import openpyxl workbook = openpyxl.load_workbook('example.xlsx') worksheet = workbook.active # 读取A1单元格的数据 data = worksheet['A1'].value print(data)