SDK error message on IntelliJ IDE

intellij-idea, java, sdk

Solution

First make sure you have installed JDK on your system. Open the command line and type: `java -version`. You should get something like:

java version "1.8.0_111"
Java(TM) SE Runtime Environment (build 1.8.0_111-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.111-b14, mixed mode)

Then open your project in IntelliJ IDEA and go to Project Structure → Project tab (Ctrl+Alt+Shift+S on Windows OS) and add new JDK by providing its local path like `C:\Program Files\Java\jdk1.8.0_60`:

Problem

I am new to this community and have this problem: I downloaded the IntelliJ IDEA IDE for Windows (x64) and i can not run a single line of code, there always comes the error message: Cannot start compiler: the SDK is not specified for module "XY". Specify the SDK at Project Structure dialog. I followed the instructions on their Website and downloaded the SDK for Windows x64 here. Now I used to set up everything, but it doesn't work as planned. In fact it is the same error as before. I am glad for any help, thanks! :)

Original source