Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug importing xlsx files with readxl = FALSE and additional parameters #152

Closed
dannyparsons opened this issue May 11, 2017 · 0 comments
Closed
Labels

Comments

@dannyparsons
Copy link

dannyparsons commented May 11, 2017

I am getting the following bug when I try to import any xlsx file with readxl = FALSE and the rows parameter.

Example:

dat <- data.frame(x = 1:20, y = 21:40)
export(dat, "dat.xlsx")
import(file = "dat.xlsx", readxl = FALSE, rows = 1:10)
# Error in read.xlsx.default(rows = ..2, xlsxFile = "dat.xlsx") : 
#  the ... list does not contain 2 elements

However, if the rows parameter comes before readxl then it works:
import(file = "dat.xlsx", rows = 1:10, readxl = FALSE)

And directly using the function also works:
openxlsx::read.xlsx("dat.xlsx", rows = 1:10)

If it helps, this only happened recently because I have this in code that I run regularly. It was only when I updated my packages a few days ago that this started to crash in this way.

Thanks.

@leeper leeper added the bug label May 14, 2017
@leeper leeper closed this as completed in b6f5072 May 14, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants