Reputation: 115
I couldn't find any other answers on StackOverflow on this. I just installed Intellij, and it can't find my JDK for some reason.
Here's what I did:
Install Java JDK 9.0.1
Note: I also have Android studio and Netbean and both have been working no problem. Heard Intellij was better than Netbean so tried using it for the first time.
Upvotes: 5
Views: 30739
Reputation: 5703
I experienced this error after adding a .sdkmanrc file to a project with
java=21.0.3-tem
It kept saying it couldn't find the SDK during the build even though it was visible in the project/module settings. Invalidating cache did not help.
I had to export my settings, open the project, then import my settings and restart and everything is good.
I lost my most recently used project on the home screen in the process but not the end of the world.
The thought came to me after reading this support article
Upvotes: 1
Reputation: 1
my solution was to reinstall and the path has already been received:
sudo apt-get install openjdk-8-jdk
the path that I put after was:
/usr/lib/jvm/
Upvotes: -2
Reputation: 734
you do not need to select the bin folder just select the path where Java is installed. Go to project structure (ctrl+alt+shift+s) and add new sdk refer to below pic for details.
Upvotes: 11