In this tutorial, I have explained the use of logger(log4j) in the JavaFX project. I have described the whole process step by step with the help of an FXML-based project created in NetBeans IDE. Also, I have given the answers to the following FAQs in this tutorial.
1) What is the location of log4j.properties file?
2) path of the log file in log4j.properties file?
3) How to use logger in multiple Java classes?
4) How write logs in a log file outside of the JavaFX project jar file?
Log4j Download link:
https://mvnrepository.com/artifact/log4j/log4j/1.2.17
log4j Properties file content file:
https://drive.google.com/file/d/1U6Kx4yNHuAf_ioyDYqMmveFyFai2f3vq/view?usp=sharing
If you find this tutorial useful, so please hit the like button to let us know. You can subscribe to my YouTube channel to learn more.