Part 3 of the tutorial, how to create a GUI application with multi forms in JAVA
So double click the button, we will be shown in the ActionEvent code. We will initialise the new form and we will set the visibility to true
Click the Start new JFrame button.
What is the response of the application?
What happens when we press X on the new JFrame?
Yes the application gets terminated. But why?
We will discuss it to part 4
To make things easy you can double click the button, it will open the code to the actionEvent.
The first thing we are going to do is to declare and initialise the new form. We will command it to show the new screen. We will observe what happens when we close the new form.
So double click the button, we will be shown in the ActionEvent code. We will initialise the new form and we will set the visibility to true
NewForm newForm = new NewForm();If we run our code, we will see the our form with a button;
newForm.setVisible(true);
Click the Start new JFrame button.
What is the response of the application?
What happens when we press X on the new JFrame?
Yes the application gets terminated. But why?
We will discuss it to part 4
No comments:
Post a Comment