Page 1 of 1

Sharing violation when importing from Excel

Posted: Thu Apr 06, 2023 4:53 am
by dougclow
Hi there

When I import data in to EViews from an Excel spreadsheet, by doing

Code: Select all

import foo.xlsx
if I have that spreadsheet open in Excel, I get an error saying "Sharing violation for file ...". It works fine if I close the spreadsheet in Excel before importing.

My team's workflow involves a lot of back-and-forth between EViews and Excel, and the spreadsheet is quite large and takes a fair while to open, so this slows me down considerably.

Curiously, I have this problem using EViews 12, but my colleague uses a much earlier version (I think 8?) and doesn't have this problem at all - he can work a lot faster than me!

They are literally the same files: we both use OneDrive to share them. I get the same results even if it's spreadsheets he's never touched, and he has no problems on spreadsheets I've created. I've tried turning AutoSave on and off, and setting it off by default in Excel Options, with no difference.

Is there anything I can do here to reduce the amount of times I'm opening and closing the same spreadsheet in Excel?

I've found a couple of previous threads that touch on this which suggest the answer is no:
https://forums.eviews.com/viewtopic.php ... 1&start=15
https://forums.eviews.com/viewtopic.php ... 012&p=3565

Many thanks.

Re: Sharing violation when importing from Excel

Posted: Thu Apr 06, 2023 10:18 am
by EViews Gareth
Unfortunately Excel has a habit of locking down files, meaning other applications cannot access them.