Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Compiling using Java 8(Getting error)
Compiling using Java 8 [message #1791115] Sat, 23 June 2018 16:40 Go to next message
Eclipse UserFriend
I get this:
Use -source 8 or higher to enable static interface method invocations

When I try to compile, Ive been told to compile on Java 8 but cant seem to figure out how. Im not sure If I have java downloaded incorrectly or if I have eclipse setup incorrectly but I really need to get this project done for an online course and my instructor just keeps sending me links to change things and when I say they dont work he just replies sorry dont know what to tell you :( Can someone please explain what Im doing wrong here and how to fix it.
Re: Compiling using Java 8 [message #1791191 is a reply to message #1791115] Mon, 25 June 2018 18:39 Go to previous messageGo to next message
Eclipse UserFriend
In Eclipse, go to Window > Preferences > Java > Installed JREs. Then either add or edit the list to point to your Java 8 JDK installation.
Re: Compiling using Java 8 [message #1791194 is a reply to message #1791191] Mon, 25 June 2018 19:15 Go to previous message
Eclipse UserFriend
After having a 1.8 Java Runtime to compile against, you also need to set
the Java Compiler preferences (or properties on the project
specifically) to comply with 1.8's language features, among other
settings you might wish to change.


http://help.eclipse.org/oxygen/topic/org.eclipse.jdt.doc.user/reference/preferences/java/ref-preferences-compiler.htm?cp=1_4_2_0_3

[Updated on: Mon, 25 June 2018 19:15] by Moderator

Report message to a moderator

Previous Topic:Too Difficult to install, to compile, to use ide, and to uninstall
Next Topic:Post Approval Wait Time
Goto Forum:
  


Current Time: Wed Feb 12 01:50:56 GMT 2025

Powered by FUDForum. Page generated in 0.08682 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top