error: No CurrentVersion entry in Software/JavaSoft registry!

error: No CurrentVersion entry in Software/JavaSoft registry!. When receiving the following problem while trying to install package xlxs in R.

Error: package or namespace load failed for ‘xlsx’:
.onLoad failed in loadNamespace() for 'rJava', details:
  call: fun(libname, pkgname)
  error: No CurrentVersion entry in Software/JavaSoft registry! 
Try re-installing Java and make sure R and Java have matching
architectures.

error: No CurrentVersion entry in Software/JavaSoft registry!

There is no entry for CurrentVersion in the Software/JavaSoft register! Reinstall Java and double-check that R and Java have the same architecture.

The problem will persist if you try to reinstall Java.

Error in x[6, ]: subscript out of bounds »

The error usually arises when the architectures of java and r (32/64 bit) do not match.

In cmd, use java -version to verify the version of Java.

You can resolve the issue by doing the following setup.

Step1:-Open Rstudio > tools > global options

Step2:-general settings > R-version > change (to the architecture same as that of java)

Step3:-Apply

Yes, That’s all issue solved. Now you can load the package.

error: JAVA_HOME cannot be determined from the Registry

You may also like...

2 Responses

  1. Wolf says:

    Nice! / I’d recommend to avoid Java dependency, if possible, e. g. via openxlsx.

    • finnstats says:

      Yes…No doubt…
      Few users are likely to be familiar with the xlsx package, therefore this solution will be beneficial to them.

Leave a Reply

Your email address will not be published. Required fields are marked *

three × one =