Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

how to make window in java

//It is easy
//Don't forget to mention package or it will cause error
import javax.swing.*;

public class coder83 {
  public static void main(String[] args){
    JFrame firstFrame = new JFrame();
//x and y are your wish
    firstFrame.setsize(y,x);
    firstFrame.setTitle("Coder83");
//It is important or else your window won't clode
    firstFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
 
    firstFrame.setVisible(true);
  }}
    
 
PREVIOUS NEXT
Tagged: #window #java
ADD COMMENT
Topic
Name
1+7 =