I'm new to Python and want to compile values located in the same address from different Excel sheets to a single one. My code, shown below is giving me trouble. Could you help me please? (the code shown below pretends to copy from one workbook to another, my final code should access many workbooks and compile all desired fields into a single Excel sheet)
import openpyxl as opl
wb1 = opl.load_workbook('C:/users/Gabriel/documents/python/python-excel/data1.xlsx')
wb2 = opl.load_workbook('c:/users/Gabriel/documents/python/python-excel/data2.xlsx')
sheet1=wb1.active
sheet2=wb2.active
a1=sheet1['A1']
a2=sheet1['A2']
a3=sheet1['A3']
sheet2['B1']=a1
sheet2['B2']=a2
sheet2['B3']=a3
wb2.save('c:/users/Gabriel/documents/python/python-excel/data2.xlsx')