Open GustavoEAvila opened 11 months ago
I am sorry that I don't know how to fix this openxlsx code, but I do know how to work around it in my code.
My Excel files are NEVER zipped, but when using loadWorkbook(), I use the default argument "isUnzipped = FALSE".
For some reason this works. I have never tried to load a zipped file.
Both of these work even though the file IS unzipped: wb <- loadWorkbook(summaryInputFilePath) wb <- loadWorkbook(summaryInputFilePath, isUnzipped = FALSE)
It is unlikely that you want isUnzipped = TRUE
. xlsx files are really just zip files in disguise. If you change the file extension to ".zip", you can extract the files to see the underlying structure. isUnzipped = TRUE
is meant to be used when you have an unzipped directory of your xlsx file's internal contents.
With isUnzipped = FALSE
(the default), loadWorkbook()
unzips your xlsx and extracts the contents for you.
loadworkbook function returns error "Error in loadWorkbook(Pla_dolar, isUnzipped = TRUE) : object 'sheetrId' not found". I have tried with different files and different locations in my files to rule out any issue with the specific file or length of the location name.
This is the image of the error if it helps in any way....
Im running R version 4.3.2 "Eye Holes" on RStudio 2023.09.1+494 "Desert Sunflower" Release (cd7011dce393115d3a7c3db799dda4b1c7e88711, 2023-10-16) for windows
openxlsx package version 4.2.5.2