> On Dec 1, 2020, at 1:51 PM, Dennis Weygand <dpweyg...@gmail.com> wrote:
> 
> From the following lines of code on an iMac running Catalina 10.15.7
> 
> 
> library(readxl)
> fname <-  "/Volumes/SD/LabData/Lorentz/Lorentz.xlsx"
> 
> Helm <- read_excel(fname,sheet="Helmholtz")
> 
> I get the following annoying error:
> Error: Evaluation error: zip file
> 
> To me this makes no sense: the file in question is not a zip file. The
> excel file in question, however, is either open on excel, or recently
> opened in excel.
> Does anyone know about this error, and what to do about it?
> I am running R version 3.5.1
> 
> Thanks for any assistance you can provide.


Hi,

Current generation MS Office files (ending with an 'x' in the file extension) 
are ZIP compressed XML files. Thus, the zip error is relevant.

If the file that you are referencing actually exists, since the error can 
indicate a non-existent file (error in name and/or path), it is possible that 
the file is still open, and read_excel() presumably requires an exclusive read 
on the file, thus cannot open it in that manner.

You might be sure that the file is not in use by Excel or another application, 
precluding an exclusive lock on the file. If so, close out the other 
application.

Another possibility is that the Excel file is password protected, and thus 
cannot be read directly, without saving it in an unprotected fashion.

Regards,

Marc Schwartz

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to