Netbeans 9/10/11 cannot run program "cmd"

No need to downgrade the JDK, just add this in your netbeans.conf

  1. Find your netbeans.conf file. e.g.: netbeansIstallDir/etc/netbeans.conf

  2. Find the key netbeans_default_options and at the start of the string add the following: -J-Djdk.lang.Process.allowAmbiguousCommands=true

    It should look like this:

    netbeans_default_options="-J-Djdk.lang.Process.allowAmbiguousCommands=true..."
    

No need to downgrade to an older JDK version, check my answer at https://stackoverflow.com/a/58484737 for a solution and the background of the change.


Fixed this issue by installing jdk1.8.0_221 as suggested here:

Java with maven wouldn't build: Cannot run program "cmd" "Malformed argument has embedded quote"

Hope this will help you too