i'd use variable column_input
later.
public static void playgame(){ btnnewbutton.addactionlistener(new actionlistener() { public void actionperformed(actionevent e) { string input = textfield.gettext(); chosen_column = integer.parseint(input); textfield.settext(null); } }); }
looks need single piece of data. easiest solution use joptionpane
. can prompt user input.
read section swing tutorial on how make dialogs more information , working examples started.
Comments
Post a Comment