Home > Back-end > To ask: why am I here can't set the layout?
To ask: why am I here can't set the layout?
Time:09-25
Red box, write setLayout error?
Package com. Chengguo. GUI;
The import javax.mail. Swing. *; Import the Java. The awt. *; Import the Java. The awt. Event. An ActionEvent; Import the Java. The awt. Event. ActionListener;
/* * * simple computer */
Public class Demo_20200506002_Calculator { Public static void main (String [] args) {
} } /* * * the calculator class */ The class Calculator extends Frame { //three text boxes TextField num1=new TextField (10); TextField num2=new TextField (10); TextField num3=new TextField (20);
//a button The Button bt=new Button ("="); //a tag The Label Label=new Label (" + "); //layout Here to write layout error!!!!!!
} /* * * event listeners class */ The class MyCalcListener implements ActionListener {
@ Override Public void actionPerformed (an ActionEvent e) {