Saving Excel export to open file

Is it possible to export to an existing excel sheet if a windows user has it open? I need to automate some export task to an excel sheet but I expect that the excel sheet will be open by other users. If it’s not possible are there workarounds available?

Thanks

No.
If a user has an Excel file open, it’s open in read/write mode. There’s a file lock on the file that prevents any other process from writing to it.
Another user or process can open the same Excel file in read-only mode. But that doesn’t help you here.

Workarounds? Possibly:

  • Pop a message to the user that the ‘Excel file will be temporarily unavailable’ or some other appropriate message
  • Save and close the file
  • Push your file content update
  • Re-open the file in the user session

But primarily this is a people problem not a technology problem. The solution in my opinion should be a people solution not a technology solution. File lock is there for a good reason; to maintain file integrity. You simply need to get a time window where the files are closed and expected to be updated via automation.

Hi Sam -

I found one work around which utilizes OneDrive. The other users can have it open as long as it’s a shared/sync’d document. The updates don’t push as smoothly as I would like but it’s possible.