this applies to all of ur JavaFX videos but you've singlehandedly saved my CS project. your videos have given me a proper understanding of most fundamental JavaFX concepts and take me through using its features in a way that's slow enough for me to understand but fast enough to not bore me to death like other tutorials. you're one of the best in the game, keep it up
if u have a problems with mouse entered, change the event from action to mouse, like this: "public void displayAvatar(MouseEvent)", but its important to use for button action event
I had the same issue and finally got it to work... The issue seems to be with the version of JavaFX and/or openJDK in the lesson vs. what I'm using and probably what you used. I'm using v22 for both but below are my notes including the last line which resolved it. // This is the lesson example but won't work. Some issue w/ the stream which results in null // Image myImage = new Image(getClass().getResourceAsStream("/images/image2.png")); // This version works but it's not JavaFX i.e. it's a work around to some stream issue. // Image myImage = new Image(String.valueOf(new File("/images/image2.png"))); // OK This actually works! AS:LKDAS:DJKH!@#!@(&*#!@# Image myImage = new Image( getClass().getResource( "/images/image2.png").toExternalForm());
Alright video overall, the only thing I did not like is that you did not show how to get scenebuilder downloaded and configuring the path. Other than that good video