-1

I'm beginning with Java and I've tried installing JavaFX on Netbeans, but I can't run anything because I get an error saying that JavaFX runtime components are missing.

I followed the instructions on the OpenJFX website and everything seemed to work fine.

I'm using Java 13 on Netbeans 11.1

Any idea where the problem is ?

  • 3
    You are likely using JDK 11+ and JavaFX is no longer included with it. – NobodyIsPerfect Nov 13 '19 at 15:46
  • I think the old Netbeans JavaFX project structure used ant (this may be totally wrong). I am guessing that's the problem. The instructions you followed on the OpenJFX site are now the correct steps to set up a JavaFX project in Netbeans at the moment. – SedJ601 Nov 13 '19 at 16:07
  • 1
    make sure you have added the VM options as described under Nr. 5 `--module-path "\path\to\javafx-sdk-12\lib" --add-modules javafx.controls,javafx.fxml` – Eritrean Nov 13 '19 at 16:12
  • I'm voting to close this question as off-topic because no question was asked. – SedJ601 Nov 13 '19 at 16:15
  • 1
    You followed the instructions and it worked? Why do you post this as a question, if you already got it working? – fabian Nov 13 '19 at 17:14
  • @NobodyIsPerfect Yep that's why I'm trying to use OpenJFX – BasileLewan Nov 14 '19 at 12:39
  • @fabian I followed the instructions to setup OpenJFX (which went as expected) but it's not working. – BasileLewan Nov 14 '19 at 12:46
  • @Sedrick Well my question is "how to get it to work ?" – BasileLewan Nov 14 '19 at 12:46

1 Answers1

0

I was missing some VM options

--module-path "\path\to\javafx-sdk-12\lib" --add-modules javafx.controls,javafx.fxml

Many thanks @Eritrean !