Error

Answered

Hi, I'm new to programming/coding etc. I've installed everything required by the course I'm doing. I have Java 12.0.1 installed, but when I run a program it returns the error java:error:release version 13 not supported. Anyone who can help with how I can fix this?

0
10 comments

Hello,

Could you please add more information about your project? Do you use any build tool (Maven/Gradle)? Please check build target in "Setting | Build...| Compiler | Java Compiler".

0
Avatar
Mariette Massyn

Hi, I was using IntelliJ IDEA. Not sure if that helps?

0

Could you please attach screenshot from "Setting | Build...| Compiler | Java Compiler"? Is it a plain Java project?

0
Avatar
Mariette Massyn

I'm sorry, don't know where to find what you're asking. Simple project,  output should be "Hello World!"

0
Avatar
Mariette Massyn

I found it

 

0
Avatar
Mariette Massyn

No idea what to change though

0

Could you please share files from .idea folder? Do you face the same issue with every new project?

0
Avatar
Mariette Massyn

First time I'm doing this. Doing an online intro course

 

https://codepen.io/Massyn/pen/BebMpq

 

0

What project type did you create? Could you please try to create new sample "Hello, World" project and check if the issue occurs there?

0

Hey Friend.

 

There's a  lot of places you must check:

- File -> Project Structure

- Edit Configurations (in drop down near RUN button)

- File -> Settings -> search for SDK

 

But what really worked for me after set everything above to my correctly Java 11 version was change this setting:

File -> Settings -> Build, Execution, Deployment -> Compiler -> Java Copiler -> Project Bytecode Version

 

This setting was pointing to Java 13, so I changed to Java 11 and everything started to work as expected

 

Good luck

0

Please sign in to leave a comment.