Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

netbeans unable to find java.lang no jdk9

I've been trying to install the new Netbeans (8.1) on jdk 9. But netbeans can't find java.lang . I checked java platform and saw this: enter image description here

the followings were added as my "platform sources" :

C:\Program Files\Java\jdk1.9.0\jrt-fs.jar
C:\Program Files\Java\jdk1.9.0\src.zip
C:\Program Files\Java\jdk1.9.0\javafx-src.zip

but i'm getting this error and can't get it work:

cannot access java.lang
  Fatal Error: Unable to find package java.lang in classpath or bootclasspath

Thanks in advance

like image 605
ipinlnd Avatar asked Feb 05 '16 07:02

ipinlnd


2 Answers

  1. Open your Project Tab
  2. Right Click on Libraries
  3. Select Properties. Project Properties will displayed.
  4. on Categories Tab select Source
  5. Set Source/Binary Format to JDK9

this is my Project Properties, but I used JDK8 My Project Properties

like image 197
AhmadDani Avatar answered Sep 28 '22 09:09

AhmadDani


Update: Netbeans nightly builds now support JDK9 ! see http://wiki.netbeans.org/JDK9Support

So download: http://bits.netbeans.org/download/trunk/nightly/latest/

like image 41
Bernhard Avatar answered Sep 28 '22 08:09

Bernhard