Java11 / JavaFX and Maven will not run outside of NetBeans IDE 9

China☆狼群 提交于 2019-11-30 17:46:16

One way to fix that would be to append the following args to the command line

--add-exports=javafx.graphics/com.sun.javafx.util=ALL-UNNAMED

I've got similar issue when doing default hello world javafx project in the IntelliJ IDEA with openjdk 11 and openjfx 11. The work around is to use offered CLI in the project configuration.

But in this case the solution is kind of hack instead of proper configuration fix. My problem was that I hadn't any module-info.java to initialize proper java platform module. Therefore the IntelliJ module is actually unnamed module. After create proper module descriptor the project is not unnamed platform module any more.

Next issue what I got is related to using external java platform module as a jar file (openjfx libs to be specific). This need to be solved by adding libraries in the project structure settings.

And then it will work without any additional CLI arguments.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!