String user1 = JOptionPane.showInputDialog("Please enter the first user's name"); JOptionPane.showMessageDialog(null, user1 + " will go first! good luck!");
and in my other class i have
I want whatever the user inputs as 'user1' to be printed in the q1 = new JLabel(user1);
how would i go about doing this?
Thanks