still works in 2024. i wish #tookotek made a validation a changed a scene to the main menu. Basically its a video of establishing db connection and username validation.
Hi I am using Java 11 which version of Scene Builder should I use? Currently, I have the latest Version downloaded (19.0) and it does not have the "OnAction" to place the Methods." Should I download the version for Java 8 and use. I am also getting an error "Exception in Application start method." ugh. Thoughts?
Hello there! Scene Builder 19 has still have OnAction however please remember that not all objects has OnAction event i.e Button will have it while Label will not. As for Java version / Scenebuilder combination, you can use version that not too far off with each other. There is no universal rule against it except for reasons like potential compatibility issue. As for "Exception in Application start method", can you please check if your fxmlloader have the correct fxml.
@@tookootek bugs found; 1. I had used a “Label” for instead of “Button” for the “Login” ans “Cancel” buttons and thus that why 1. I could fine the “OnAction” in Scene Builder. Secondly, after correcting my error, I created duplicates of “cancelButton” in login.fxml which max my Application Crash giving me that error message. What a Noob. Great lesson in debugging.
@@mastershonobi110 Excellent work! Error is always very much welcome and I personally recommend to work with lots lots of them while they are free. Coding without error is usually good only on production releases but for learning, they are highly recommended whether intentionally done or not. It is part of good learning.
Hello there my friend. Your code is having issue connecting to your database. Please ensure that the DB account you use is working with your local database.
Do you have a method or variable variable named isBlank? If it is a method, ensure you got the name right however if it is variable, ensure it was declared.
I did everything but my main class just won't run the window I made in scene builder? It just shows an empty window from the beggining. Maybe I need to update something? I'm using NetBeans 12.0
Hey there Dragan, the main class should atleast have below. Ensure that your "login.fxml" is using the corresponding controller, you can check that in the FMXL or Scene Builder. ... public void start(Stage primaryStage) throws Exception{ Parent root = FXMLLoader.load(getClass().getResource("login.fxml")); primaryStage.setTitle("Hello World"); primaryStage.setScene(new Scene(root, 520, 400)); primaryStage.show(); }
Thanks man for giving me a clue, I will let YT copyright management handle that. There are couple of them that copied my videos by trimming the start and end however YT algorithm is too smart to fall for that. By the way this login screen has another version. Either you saw the first version or the one that was copied and re-uploaded by someone. Happy Learning!
I don't seem to be getting the correct result from my 'String verifyLogin' statement. When I run the query directly, I get a correct result of 1 but when I do it in the I get 0, even though I've validated the connection by having the table details printed to console.
@@tookootek I'm not getting the issue now as I changed my code to be 'String verifyLogin = "SELECT username, password from User";' I think the issue was that it was looping through all the logins stored in the database and I hadn't coded it to stop after a successful hit.
Hi Tidus & Rod, You can add sort of "Role" field. One of the simplest is add a new boolean field, i.e isAdmin the value is just between true or false however you can also use string or number type, it totally depends on how many user you have and how much flexible you want it.
I still get the error at 34:18 along side with this error :"Cannot invoke "java.sql.Connection.createStatement()" because "connectDB" is null" even after i add the jar file (lastes version). what can i do pls
Hi Ankel, check your DatabaseConnection.java specifically check getConnection() method under DatabaseConnection class - the variables, login account and connection string you use. It might be just a a simple typo in one of them. ConnectDB is null error just telling you it got nothing from trying to establish that connection when you call getConnection().
Hello bro , just 1 thing, when i run the Select count(1) on sql it displays the 1 but when i put the correct username and password on the little Login window it still says Invalid Login, how do i fix this?
tookootek 1 second ago Hello There Jakuzo! If you just got Invalid Login then this is good, you are able to connect to your DB and Table. The first we can do is try to "Hard Code" the login and password and try to run again. If that works then it means you might just have extra space in between concat either in Username or Password. You can revert back to username and password TextFields once you resolve the issue. Let me know, there are couple of things we can check what went wrong.
Thank for do this amazing video, i learn some concepts today and all worked fine to my project. now i will assist more video that u created. sorry for my inglish, i just a brazilian trying to do something cool, and keep going with your videos.
Hello there Eoghan, IntelliJ IDEA is a good start for JavaFX using Maven, I don't have one yet but I am pretty sure there are coupe of videos that already tackle this. It should give you a good start
Hello S K! In the DatabaseConnection class, have you filled out the Username and password? if you did, please try to login directly to your database if you get the same error. Getting Access Denied error is excellent, it means you are halfway to successfully connecting. You were able to setup the correct connection string, you just need to have a proper account.
Hey bro! thanks for watching my video, it is in the works but not sure when I can complete and upload it as there is one or two videos ahead of it. But i am hoping soon.
@@tookootek But it closes without validating the username or account, so if I hit the login button it automatically closes even though the account is incorrect
Thanks you for the great lesson ☺️ I can with a question and I need help from you and others following through. What can cause my login UI to freeze and stops responding afterwards and when I kill the the process am getting this error message in my intellij idea terminal: process finished with exit code -805306369 (0x0fffffff) What can cause this error thanks for the help
I usually don't comment on videos, but this one deserves, congratulations for this content, very helpful!
still works in 2024. i wish #tookotek made a validation a changed a scene to the main menu. Basically its a video of establishing db connection and username validation.
Hi I am using Java 11 which version of Scene Builder should I use? Currently, I have the latest Version downloaded (19.0) and it does not have the "OnAction" to place the Methods." Should I download the version for Java 8 and use. I am also getting an error "Exception in Application start method." ugh. Thoughts?
Hello there! Scene Builder 19 has still have OnAction however please remember that not all objects has OnAction event i.e Button will have it while Label will not. As for Java version / Scenebuilder combination, you can use version that not too far off with each other. There is no universal rule against it except for reasons like potential compatibility issue. As for "Exception in Application start method", can you please check if your fxmlloader have the correct fxml.
@@tookootek I will check and let you know. I am really enjoying your vids. Ty for responding; I appreciate it.
@@tookootek bugs found; 1. I had used a “Label” for instead of “Button” for the “Login” ans “Cancel” buttons and thus that why 1. I could fine the “OnAction” in Scene Builder. Secondly, after correcting my error, I created duplicates of “cancelButton” in login.fxml which max my Application Crash giving me that error message. What a Noob. Great lesson in debugging.
@@mastershonobi110 Excellent work! Error is always very much welcome and I personally recommend to work with lots lots of them while they are free. Coding without error is usually good only on production releases but for learning, they are highly recommended whether intentionally done or not. It is part of good learning.
Hi, how do I have the components resize automatic using Scene Builder when I maximize the UI? How can I make it “auto size” when the UI is stretched?
Aslam o alaikum sir, Whenever I run program it display error " Access denied for user @ local host ' using password :no" Any solution??
Hello there my friend. Your code is having issue connecting to your database. Please ensure that the DB account you use is working with your local database.
cannot resolve class "sampleController"
edit: its fixed was a small issue but now its telling me it cannot find symbol isBlank()
Do you have a method or variable variable named isBlank? If it is a method, ensure you got the name right however if it is variable, ensure it was declared.
@@tookootek i used isempty instead it works but ill try to fix it thank you im trying to setup the database rn amazing video btw.
I did everything but my main class just won't run the window I made in scene builder? It just shows an empty window from the beggining. Maybe I need to update something? I'm using NetBeans 12.0
Hey there Dragan, the main class should atleast have below. Ensure that your "login.fxml" is using the corresponding controller, you can check that in the FMXL or Scene Builder.
...
public void start(Stage primaryStage) throws Exception{
Parent root = FXMLLoader.load(getClass().getResource("login.fxml"));
primaryStage.setTitle("Hello World");
primaryStage.setScene(new Scene(root, 520, 400));
primaryStage.show();
}
Dude you copied the other guy on youtube with exact same video
Thanks man for giving me a clue, I will let YT copyright management handle that. There are couple of them that copied my videos by trimming the start and end however YT algorithm is too smart to fall for that.
By the way this login screen has another version. Either you saw the first version or the one that was copied and re-uploaded by someone.
Happy Learning!
Check on this, you can share ruclips.net/video/QsTOAXAtdrM/видео.html
Who cares. Sharing is caring
Plugin 'org.apache.maven.plugins:maven-compiler-plugin:3.8.1' not found
how to fix it?
bro are u komang saputra?
I don't seem to be getting the correct result from my 'String verifyLogin' statement. When I run the query directly, I get a correct result of 1 but when I do it in the I get 0, even though I've validated the connection by having the table details printed to console.
Hey John are you still having this issue? can you share your String here?
@@tookootek I'm not getting the issue now as I changed my code to be 'String verifyLogin = "SELECT username, password from User";'
I think the issue was that it was looping through all the logins stored in the database and I hadn't coded it to stop after a successful hit.
@@JohnRehill good job! The thrill of debugging lives on! Keep it up my friend, you are in the right track.
After three days of suffering over this video, I have finally done it. Tysm!
Welcome to coding world! May sometimes frustrating but so rewarding once you've make it work!
Thanks a lot!!! Helped me!
Excellent Teaching method ...Respect
Bro, two years later and this video is amazing, thank you
why cant I see the image? I checked and my fxml file is good and the directories as well
Hi everyone how to differentiate between a user and an admnin when logging in?
Hi Tidus & Rod, You can add sort of "Role" field. One of the simplest is add a new boolean field, i.e isAdmin the value is just between true or false however you can also use string or number type, it totally depends on how many user you have and how much flexible you want it.
Using the "role" field, you can control what level of access the user will have or what functionality will going to be available
@@tookootek Thank you very very very much, helpfull !!!! :)
does anyone know where to download javaf sdk?
Thank for making this video I love how straight to the point you are with your tutorials! Saves me a ton of time!
I still get the error at 34:18 along side with this error :"Cannot invoke "java.sql.Connection.createStatement()" because "connectDB" is null" even after i add the jar file (lastes version). what can i do pls
Hi Ankel, check your DatabaseConnection.java specifically check getConnection() method under DatabaseConnection class - the variables, login account and connection string you use. It might be just a a simple typo in one of them. ConnectDB is null error just telling you it got nothing from trying to establish that connection when you call getConnection().
u absolutely komeng
Thanks komang we all love you so much :***
URI is not registered (Settings | Languages & Frameworks | Schemas and DTDs), how can I solve this ? At the end of part 2.
Check this if it can help you can as well share link ruclips.net/video/QsTOAXAtdrM/видео.html
Hello bro , just 1 thing, when i run the Select count(1) on sql it displays the 1 but when i put the correct username and password on the little Login window it still says Invalid Login, how do i fix this?
tookootek
1 second ago
Hello There Jakuzo! If you just got Invalid Login then this is good, you are able to connect to your DB and Table. The first we can do is try to "Hard Code" the login and password and try to run again. If that works then it means you might just have extra space in between concat either in Username or Password. You can revert back to username and password TextFields once you resolve the issue. Let me know, there are couple of things we can check what went wrong.
Thank for do this amazing video, i learn some concepts today and all worked fine to my project. now i will assist more video that u created. sorry for my inglish, i just a brazilian trying to do something cool, and keep going with your videos.
You are welcome! Keep on coding!
This is very fast , I can't understand what you are doing 👎
Check on this, you can share if you love it ruclips.net/video/QsTOAXAtdrM/видео.html
Thank you
Nice tutorial
What are the maven ide plugins that you recommend for this?
Hello there Eoghan, IntelliJ IDEA is a good start for JavaFX using Maven, I don't have one yet but I am pretty sure there are coupe of videos that already tackle this. It should give you a good start
at the end when i click login i get following error:
SQLException: Access denied for user 'whatever'@'localhost'
Hello S K! In the DatabaseConnection class, have you filled out the Username and password? if you did, please try to login directly to your database if you get the same error.
Getting Access Denied error is excellent, it means you are halfway to successfully connecting. You were able to setup the correct connection string, you just need to have a proper account.
@@tookootek i found the mistake. i added a new user to the table UserAccount and tried to login with it. Then i used my root account and it worked!
Watching with my hubby.. This reminds me of my collage days, learning vb6
Love to hear that!
can you tutorial about hibernate ?
PLEASE MAKE A TUTORIAL ON HOW TO DISPLAY CONTENT FROM DATABASE IN TABLE VIEW(JAVAFX) 😭😭😭
Hey bro! thanks for watching my video, it is in the works but not sure when I can complete and upload it as there is one or two videos ahead of it. But i am hoping soon.
@@tookootek please do a video about how to print a bill information on javafx with scene builder please i didn't find any tutorial on youtube about it
ERES UN GRANDEEEEEEEEEE, LIKE Y SUB
How to make it so that when its. resized to full screen the components stays on middle of anchor pane?
did you find out how ? i'm struggrling to find out
Do you know how to automatically close the log in window after a successful log in?
Try to add something like this in the Log in button.
Stage stage = (stage) logInButton.getScene().getWindow();
stage.close();
@@tookootek But it closes without validating the username or account, so if I hit the login button it automatically closes even though the account is incorrect
Nevermind I fixed it, thanks by the way!
thanks a lot!!! helped me with my assignment and exam.
Glad it helped!
Came here from a question I had from other of your videos. Thank you so much it helped me to notice my error. Amazing videos!!
You're Welcome! Thanks Karla. Enjoy and keep on coding!
21:20
Thank you very much for your help!
You're welcome!
Thanks you for the great lesson ☺️ I can with a question and I need help from you and others following through. What can cause my login UI to freeze and stops responding afterwards and when I kill the the process am getting this error message in my intellij idea terminal:
process finished with exit code -805306369 (0x0fffffff)
What can cause this error thanks for the help
Thank you so much sir. You really helped me so much on doing this. Thank you again sir!
aai baapane nashta nahi dila ka re