Hi friends, If you have been using JavaFX 8 and haven't tried any newer version, you definitely should checkout JavaFX 11 or later versions. From version 11 onwards, the project is completely opensource (github.com/openjdk/jfx) and there have been a lot of feature improvements and bugfixes. If you love JavaFX and like to keep updated regularly, you can follow Mr. Johan Vos on twitter (twitter.com/johanvos).
Thank you for the tutorial. Do you think you can make a video of how to create a standalone JavaFX app using the new JPackage? I've been trying to do that with JavaFX and SQLite but I can't.
[Important point] A lot of people were asking why they are getting "Caused by: java.lang.NullPointerException: Location is required" error when building JavaFX with Gradle. It is because, the FXML, CSS, and similar non-java resources are not added to your package correctly. You can fix this by adding the following lines in your build.gradle file (This will include FXML, CSS and PNG(For icons) in your source set). sourceSets.main.resources.srcDirs("src/main/java").includes.addAll(["**/*.fxml", "**/*.css", "**/*.png"]) sourceSets.main.resources.srcDirs("src/main/resources").includes.addAll(["**/*.*"])
Thank you bro, I have been strugling for about 48 hours straight now ! You saved me :D EDIT: NEW PROBLEM! When creating a jar file for distribution, the application does not launch, after several modificatins and tries, I have found the problem but not the solution: The program is still asking for the Location. I couldn't find the solution anywhere hopefully you can guide us through this problem. Many thanks to you for all your work, keep it up!
hi mate thanks a lot for the tuto can you help please with table-view I need to make the table cell size and height change depending on text size I will be so grateful for help thanks a lot
These are the kind of things I've been waiting from you. Keep it up bro. How about a full java management software development from scratch with javafx 14 and MySQL? That would be very nice.
Thanks brother. I have prepared a new JavaFX 14 simple project from scratch. It will be released soon. But it doesn't have MySQL though. The reason why I am not doing another big project is, I already have a JavaFX SQL based (Derby) Library Management system tutorial series with 43 videos. So again going through same concepts and ideas is bit hard.
Hi sir can you make tutorial on how to create custom jre with modular project with jasperreport. I tried but it give me automatic module error while creating custom jre
Hi, Taking 22 minutes to explain this was my conscious decision/fault rather than JavaFX's. I wanted to explain each and everything for helping absolute beginners. For any person who is creating his project 2nd or later times, it won't take more than 1 minute to get the project initialized. Java is always developer-friendly if the developer knows it.
@@GenuineCoder Comrade, I understood, and I'm sorry if it seemed like a criticism of your work. I am grateful for people like you to publish this type of material, but even with an advanced level of knowledge it is still very much just to start a project (it may not take 20 minutes or even 5, but the number of steps is still huge). As I said I love Java, but it is far from being friendly.
Sir.. Im using scenebuilder 11 with JDK 14 , Sdk 14 but In my Scenebuilder library I imported JFoenix 9.0 but i can only use few components , When i used the other it appears error on my screen how do i do ?
@@GenuineCoder Sir, I can't use JFxProgressBar and JFXTextField and etc.. When i used them and this appeared ! Exception in Application start method java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:564) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:464) at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:363) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:564) at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:1051) Caused by: java.lang.RuntimeException: Exception in Application start method at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:900) at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195) at java.base/java.lang.Thread.run(Thread.java:832) Caused by: java.lang.IllegalAccessError: class com.jfoenix.skins.JFXProgressBarSkin (in unnamed module @0x6fd0aec5) cannot access class com.sun.javafx.scene.NodeHelper (in module javafx.graphics) because module javafx.graphics does not export com.sun.javafx.scene to unnamed module @0x6fd0aec5 at com.jfoenix.skins.JFXProgressBarSkin.(JFXProgressBarSkin.java:64) at com.jfoenix.controls.JFXProgressBar.createDefaultSkin(JFXProgressBar.java:75) at javafx.controls/javafx.scene.control.Control.doProcessCSS(Control.java:897) at javafx.controls/javafx.scene.control.Control$1.doProcessCSS(Control.java:89) etc....
@@vastolord1752 The problem is with the 'module' concept introduced with Java 9. This issue raised in JFoenix GitHub repo discuss this very issue: github.com/jfoenixadmin/JFoenix/issues/889 Have a look at the issue thread and that should fix your issue. Related StackOverflow question: stackoverflow.com/questions/53037442/how-to-fix-jfoenix-modules-with-javafx-11
Hi, A project is in the pipeline. It will be released soon. You can find the project in Github if interested: github.com/afsalashyana/Covid19-Desktop-Widget
You should definitely try migrating to JavaFX 11 or later. There has been a lot of changes since JavaFX 8. Moreover from 11 onwards, JavaFX (OpenJFX) is completely opensource. OpenJFX Project in Github: github.com/openjdk/jfx
@@GenuineCoder can you make a video, which includes how to export this project to standalone application / JAR. Which runs on windows. I have two client projects which i have done in Javafx8 / java 8. But now i want them to update on java 11 / javafx 14. I have tried to build jar of this application using documentation from intellj but in the end it says java 11 does not include deploy of fx projects. On documentation page it is also written that packaging javafx application is only possible with java 8 only.
@@tabish__ali You can build JAR with the help of Gradle. You can make use of "*distZip*" task in gradle to build a zip that contains everything to run the application (docs.gradle.org/current/userguide/distribution_plugin.html) I have added a sample of build.gradle that you can use with your JavaFX application. gist.github.com/afsalashyana/25b0d1774cd801f082d7d7cc2c66cbf7 All your libraries will be added to a dedicated lib/ folder and will be available inside the zip.
Hi friends,
If you have been using JavaFX 8 and haven't tried any newer version, you definitely should checkout JavaFX 11 or later versions.
From version 11 onwards, the project is completely opensource (github.com/openjdk/jfx) and there have been a lot of feature improvements and bugfixes. If you love JavaFX and like to keep updated regularly, you can follow Mr. Johan Vos on twitter (twitter.com/johanvos).
Thank you for the tutorial. Do you think you can make a video of how to create a standalone JavaFX app using the new JPackage? I've been trying to do that with JavaFX and SQLite but I can't.
any incoming tutorial on how to create an executable JavaFX app? (including dependencies like mysql, hibernate etc)
Why u need a video for that? Just like you would do with Java app lol
[Important point]
A lot of people were asking why they are getting "Caused by: java.lang.NullPointerException: Location is required" error when building JavaFX with Gradle.
It is because, the FXML, CSS, and similar non-java resources are not added to your package correctly.
You can fix this by adding the following lines in your build.gradle file (This will include FXML, CSS and PNG(For icons) in your source set).
sourceSets.main.resources.srcDirs("src/main/java").includes.addAll(["**/*.fxml", "**/*.css", "**/*.png"])
sourceSets.main.resources.srcDirs("src/main/resources").includes.addAll(["**/*.*"])
Thank you bro, I have been strugling for about 48 hours straight now ! You saved me :D
EDIT: NEW PROBLEM! When creating a jar file for distribution, the application does not launch, after several modificatins and tries, I have found the problem but not the solution: The program is still asking for the Location. I couldn't find the solution anywhere hopefully you can guide us through this problem.
Many thanks to you for all your work, keep it up!
Check out how you can configure VS Code for Java and JavaFX development: ruclips.net/video/IPhqJh4ckWA/видео.html
hi mate thanks a lot for the tuto can you help please with table-view I need to make the table cell size and height change depending on text size I will be so grateful for help thanks a lot
Download the JDK from Oracle, not Azul.
Hello Genuine Coder, please provide tutorial for JAVAFX 14 with Spring.
request. javafx 14 module + springframework/springboot + databases
Thank you...
These are the kind of things I've been waiting from you. Keep it up bro. How about a full java management software development from scratch with javafx 14 and MySQL? That would be very nice.
Thanks brother.
I have prepared a new JavaFX 14 simple project from scratch. It will be released soon. But it doesn't have MySQL though.
The reason why I am not doing another big project is, I already have a JavaFX SQL based (Derby) Library Management system tutorial series with 43 videos. So again going through same concepts and ideas is bit hard.
Love you 👍
Hi sir can you make tutorial on how to create custom jre with modular project with jasperreport. I tried but it give me automatic module error while creating custom jre
I love java, but taking half an hour to set up a Hello World is a pain in the ass.
Hi, Taking 22 minutes to explain this was my conscious decision/fault rather than JavaFX's. I wanted to explain each and everything for helping absolute beginners. For any person who is creating his project 2nd or later times, it won't take more than 1 minute to get the project initialized.
Java is always developer-friendly if the developer knows it.
@@GenuineCoder Comrade, I understood, and I'm sorry if it seemed like a criticism of your work. I am grateful for people like you to publish this type of material, but even with an advanced level of knowledge it is still very much just to start a project (it may not take 20 minutes or even 5, but the number of steps is still huge). As I said I love Java, but it is far from being friendly.
Thanks for the info! Do you know how to export your java project into a standalone project that is able to run from the jar file?
I've set up my project like that. Maybe it'll help you - github.com/gravetii/wordagam
this video about how to export javafx 11 or 13 to excuteable jar file
ruclips.net/video/HGHu-SzL-5E/видео.html
Me I know
Javafx 😎
please give a link to the picture of your desktop
Great JavaFX I work with this allways, I hope this and new releases
Bert good, thanks for sharing.
Nice video! Is there any free IDE you recommend to get started because Intellij costs $$$ ?
Use netbeans eclipse
Intellij is available as a community edition also. That is free.
Sir..
Im using scenebuilder 11 with
JDK 14 , Sdk 14 but
In my Scenebuilder library
I imported JFoenix 9.0 but i can only use few components ,
When i used the other it appears error on my screen how do i do ?
What is the error you are getting?
I just imported JFonix 9.0.9 to Scene Builder 11. It is working fine in my end.
@@GenuineCoder Sir, I can't use JFxProgressBar and JFXTextField and etc..
When i used them and this appeared !
Exception in Application start method
java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplicationWithArgs(LauncherImpl.java:464)
at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication(LauncherImpl.java:363)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:564)
at java.base/sun.launcher.LauncherHelper$FXHelper.main(LauncherHelper.java:1051)
Caused by: java.lang.RuntimeException: Exception in Application start method
at javafx.graphics/com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:900)
at javafx.graphics/com.sun.javafx.application.LauncherImpl.lambda$launchApplication$2(LauncherImpl.java:195)
at java.base/java.lang.Thread.run(Thread.java:832)
Caused by: java.lang.IllegalAccessError: class com.jfoenix.skins.JFXProgressBarSkin (in unnamed module @0x6fd0aec5) cannot access class com.sun.javafx.scene.NodeHelper (in module javafx.graphics) because module javafx.graphics does not export com.sun.javafx.scene to unnamed module @0x6fd0aec5
at com.jfoenix.skins.JFXProgressBarSkin.(JFXProgressBarSkin.java:64)
at com.jfoenix.controls.JFXProgressBar.createDefaultSkin(JFXProgressBar.java:75)
at javafx.controls/javafx.scene.control.Control.doProcessCSS(Control.java:897)
at javafx.controls/javafx.scene.control.Control$1.doProcessCSS(Control.java:89)
etc....
@@vastolord1752
The problem is with the 'module' concept introduced with Java 9.
This issue raised in JFoenix GitHub repo discuss this very issue: github.com/jfoenixadmin/JFoenix/issues/889
Have a look at the issue thread and that should fix your issue.
Related StackOverflow question: stackoverflow.com/questions/53037442/how-to-fix-jfoenix-modules-with-javafx-11
Thanks Sir !
Great explanation. Thank you.
Very good
First like and first comment 😎
nice, keep up the good work! by the way where are you from?
Thanks.
I am from Kerala, India.
It will be cool to build a full project in javaFx 11+
Hi,
A project is in the pipeline. It will be released soon.
You can find the project in Github if interested: github.com/afsalashyana/Covid19-Desktop-Widget
@@GenuineCoder ok boss
Can't wait
thanks sir, i have been using javafx 8 with jdk 8, now thinking that i might go for latest version.
You should definitely try migrating to JavaFX 11 or later.
There has been a lot of changes since JavaFX 8. Moreover from 11 onwards, JavaFX (OpenJFX) is completely opensource.
OpenJFX Project in Github: github.com/openjdk/jfx
@@GenuineCoder can you make a video, which includes how to export this project to standalone application / JAR. Which runs on windows. I have two client projects which i have done in Javafx8 / java 8.
But now i want them to update on java 11 / javafx 14. I have tried to build jar of this application using documentation from intellj but in the end it says java 11 does not include deploy of fx projects.
On documentation page it is also written that packaging javafx application is only possible with java 8 only.
@@tabish__ali
You can build JAR with the help of Gradle.
You can make use of "*distZip*" task in gradle to build a zip that contains everything to run the application (docs.gradle.org/current/userguide/distribution_plugin.html)
I have added a sample of build.gradle that you can use with your JavaFX application. gist.github.com/afsalashyana/25b0d1774cd801f082d7d7cc2c66cbf7
All your libraries will be added to a dedicated lib/ folder and will be available inside the zip.
this video about how to export javafx 11 or 13 to excuteable jar file
ruclips.net/video/HGHu-SzL-5E/видео.html
azulu is good as oracal JDK?
It is in a way better than Oracle JDK.
Zulu JDK is built from Open JDK. You can use it without any issues.
@@GenuineCoder thank u very much!
The only problem is that the Wyswyg designer for JavaFX SUCKSSSS compared to that of WPF in Visual Studio.