Python Forum
Read and write active Excel file
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Read and write active Excel file
#1
Hi, is it possible to read and write an active Excel workbook? All I have found so far, is either create a new Excel and write inn, or provide a path to an Excel file, and then read / write (but the file needs to be closed before the script runs, otherwise it will fail). I hope there are some ways to work with an active Excel file?

from openpyxl import Workbook
wb = Workbook() # creates a new Excel
wb_obj = openpyxl.load_workbook(path) # or load an Excel with a path
Reply


Messages In This Thread
Read and write active Excel file - by euras - Jun-27-2021, 07:58 PM
RE: Read and write active Excel file - by Larz60+ - Jun-28-2021, 09:42 AM
RE: Read and write active Excel file - by Larz60+ - Jun-29-2021, 03:42 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  What does .flush do? How can I change this to write to the file? Pedroski55 3 223 Apr-22-2024, 01:15 PM
Last Post: snippsat
  Python openyxl not updating Excel file MrBean12 1 339 Mar-03-2024, 12:16 AM
Last Post: MrBean12
  Copy Paste excel files based on the first letters of the file name Viento 2 451 Feb-07-2024, 12:24 PM
Last Post: Viento
  Last record in file doesn't write to newline gonksoup 3 439 Jan-22-2024, 12:56 PM
Last Post: deanhystad
  Recommended way to read/create PDF file? Winfried 3 2,901 Nov-26-2023, 07:51 AM
Last Post: Pedroski55
  write to csv file problem jacksfrustration 11 1,548 Nov-09-2023, 01:56 PM
Last Post: deanhystad
  python Read each xlsx file and write it into csv with pipe delimiter mg24 4 1,469 Nov-09-2023, 10:56 AM
Last Post: mg24
  Search Excel File with a list of values huzzug 4 1,259 Nov-03-2023, 05:35 PM
Last Post: huzzug
  Updating sharepoint excel file odd results cubangt 1 853 Nov-03-2023, 05:13 PM
Last Post: noisefloor
  Active Directory integration dady 2 513 Oct-13-2023, 04:02 AM
Last Post: deanhystad

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020