Create JFrame in java
package framecreate;
import javax.swing.JFrame;
public class myClass {
public static void main(String[]args){
JFrame frame = new JFrame();
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.setVisible(true);
frame.setSize(400, 300);
frame.setTitle("this is JFrame");
}
}
No comments:
Post a Comment