Is it possible to update a spreadsheet open in Excel in real-time? I have the following Python code that tries to update cell B1 with the text "ID" in an Excel worksheet called Example.xlsx:
import openpyxl
wb = openpyxl.load_workbook('Example.xlsx')
sheet = wb['Sheet']
sheet['B1'] = 'ID'
wb.save('Example.xlsx')
On running the script I get this error:
PermissionError: [Errno 13] Permission denied: 'Example.xlsx'. I'm aware that this is the case because Excel is currently opening the file, but I was wondering if there was another method or module I could use to update a sheet while it is open.