1
> library(xlsx)
Error : .onAttach failed in attachNamespace() for 'xlsx', details:
  call: .jnew("org/apache/poi/xssf/usermodel/XSSFWorkbook")
  error: java.lang.NoClassDefFoundError
Error: package or namespace load failed for ‘xlsx’

Is there any requirement in JDK that I am missing?

Also in the same breath, I keep getting a different kind of error in another Windows system like below, which says it can't find the dlls of Java software, despite Java being installed and environment variables set.

> library(xlsx)
Loading required package: rJava
Error : .onLoad failed in loadNamespace() for 'rJava', details:
  call: inDL(x, as.logical(local), as.logical(now), ...)
  error: unable to load shared object 'E:/R Project/Softwares/R-  3.1.2/library/rJava/libs/x64/rJava.dll':
  LoadLibrary failure:  The specified module could not be found.

Error: package ‘rJava’ could not be loaded
sunitprasad1
  • 768
  • 2
  • 12
  • 28
  • Did you look at http://stackoverflow.com/questions/6492361/problem-loading-rjava/7604433#7604433 and http://stackoverflow.com/questions/26549829/does-xlconnect-package-work-with-java-8 and http://stackoverflow.com/questions/9120270/how-can-i-install-rjava-for-use-with-64bit-r-on-a-64-bit-windows-computer/9120712#9120712 – lawyeR Feb 24 '15 at 10:17
  • The problem with rJava has a solution [here](http://stackoverflow.com/a/15998666/2591234) – shadow Feb 24 '15 at 10:17
  • I get these problems when I try to use `xlsx` (and by extension `rJava`) in 64-bit R. An immediate work around is to use 32-bit R. – James Feb 24 '15 at 10:39
  • 1
    Incorrect, I still have the error in a 32-bit R environment. – Amit Kohli Aug 23 '16 at 10:51

0 Answers0