I am trying to add VM options but when I do I experience this error. I'm currently using Maven with the current version of IntelliJ and JavaFX 18.0.1 on Windows 10 64x
"C:\Program Files\Amazon Corretto\jdk11.0.15_9\bin\java.exe" --module-path C:\Users\tommy\Documents\Javafx\openjfx-18.0.1_windows-x64_bin-sdk\javafx-sdk-18.0.1\lib --add-modules javafx.controls,javafx.fxml "-javaagent:C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2022.1.1\lib\idea_rt.jar=54563:C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2022.1.1\bin" -Dfile.encoding=UTF-8 -classpath C:\Users\tommy\.m2\repository\org\openjfx\javafx-controls\11.0.2\javafx-controls-11.0.2.jar;C:\Users\tommy\.m2\repository\org\openjfx\javafx-graphics\11.0.2\javafx-graphics-11.0.2.jar;C:\Users\tommy\.m2\repository\org\openjfx\javafx-base\11.0.2\javafx-base-11.0.2.jar;C:\Users\tommy\.m2\repository\org\openjfx\javafx-fxml\11.0.2\javafx-fxml-11.0.2.jar;C:\Users\tommy\.m2\repository\org\openjfx\javafx-web\11.0.2\javafx-web-11.0.2.jar;C:\Users\tommy\.m2\repository\org\openjfx\javafx-media\11.0.2\javafx-media-11.0.2.jar -m com.example.hellofx/com.example.hellofx.HelloApplication
Error occurred during initialization of boot layer
java.lang.module.FindException: Module com.example.hellofx not found
Here is the argument I am adding for my VM options
--module-path "C:\Users\tommy\Documents\Javafx\openjfx-18.0.1_windows-x64_bin-sdk\javafx-sdk-18.0.1\lib" --add-modules javafx.controls,javafx.fxml
In addition to testing this one, both have the necessary files
--module-path "C:\Users\tommy\Documents\Javafx\lib" --add-modules javafx.controls,javafx.fxml
I have tried using spaces instead of the double quotes, I have tried rebuilding my project, moving the project folder, moving the library folder. Nothing has worked so far.
When I don't add VM options it seems to run just fine, however, I have not tested coding anything on it other than the default test it gives.