我目前正在使用JCreator,并且无法找到我的代码有什么问题,由于某种原因它不能读取我输入的内容JTextField.我不打算彻底改变我的代码,如果any1可以指出我做错了什么,或者给我一些它应该是什么样的代码示例,这将是很好的.再次,当他们做同样的事情时,不要寻找"这比这更好".
import java.awt.*;
import javax.swing.*;
import java.util.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class Wall extends JApplet implements ActionListener {
double count;
Boolean Submit = false;
JButton btn1;
JTextField tf,field;
int x = 0;
int y = 575;
int x1 = 50;
int y1 = 25;
int textnumber;
Random randomNum = new Random();//initialize random variable
int count2;
public void init() {
setLayout( new FlowLayout( ) );
tf = new JTextField(5);
field = new JTextField( "<===== Enter Brick …Run Code Online (Sandbox Code Playgroud)