0

I installed 64 bit version of C/C++ version of netbeans from here https://netbeans.org/downloads/ I am using Cygwin to work with netbeans 8.2 things upto here are fine , I needed java for one of my projects so I downloaded jdk-10.0.2_windows-x64_bin and installed it in E:\installation2\java

The path variable and other settings are

PATH=C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Program Files (
x86)\PC Connectivity Solution\;C:\Windows\system32;C:\Windows;C:\Windows\System3
2\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\WIDCOMM\Blue
tooth Software\;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\cygwin64
\bin;E:\installation2\putty\;C:\Program Files\Java\jdk-10.0.2\bin;E:\installatio
n2\python3\Scripts\;E:\installation2\python3\;

C:\Users\>java --version
java 10.0.2 2018-07-17
Java(TM) SE Runtime Environment 18.3 (build 10.0.2+13)
Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.2+13, mixed mode)

However when I try to create a new project in netbeans8.2 for Java I don't get that options.Here is a screenshot of Java Platform manager on Netbeans Tools--->Java Platfoms window enter image description here

In a notepad I am able to write Java programs and compile them and execute them but not in netbeans 8.2 I am not able to understand why Netbeans8.2 is not able to create Java project. What can I do to fix this?What is the mistake in above configuration?

Community
  • 1
  • 1
ss321c
  • 689
  • 2
  • 11
  • 23
  • 1
    Since NetBeans 8.2 does not support any JDK release > 8, you have a choice: stick with NetBeans 8.2 and use JDK 1.8, or [download and install Apache NetBeans 9](http://netbeans.apache.org/download/index.html), and use JDK 10. See [How can I install Netbeans with JDK 10](https://stackoverflow.com/q/49502600/2985643) for details. Also see [Netbeans 9 C++ Support] (https://stackoverflow.com/q/51493882/2985643) for using C++ with NetBeans 9.0. Note that you can safely run NetBeans 8.2 and NetBeans 9.0 concurrently. – skomisa Sep 03 '18 at 19:38

1 Answers1

0

You need to have the Java SDK (JDK) installed, instead of the JRE. Simply download JDK 8 from Oracle (not 9 or 10+ because these are not supported by NB 8.2) and install it. Then you can edit the Netbeans config file to point to the JDK:

Edit netbeans.conf file in C:\Program Files\NetBeans 8.2\etc\:

netbeans_jdkhome="C:\Program Files\Java\jdk1.8.0_xyz" 

Alternatively, you can delete the existing platform and create a new Java platform in the Netbeans Platform Manager, pointing to the JDK path.

albogdano
  • 2,710
  • 2
  • 33
  • 43