Of course the JOptionPane will not pop up unless there is an error on JTextFiled. That is the purpose of using JOptionPane.showMessageDialog.
I intentionally make an error on JTextField, then JOptionPane.showMessageDialog opens. I click on OK button to close the JOptionPane, after that, it
will open the same JOptionPane.showMessageDialog again and the action keep repeating.
Please help. Thanks a lot.
Rob Spoor wrote:Please show us an SSCCE that shows this behaviour, because a JOptionPane dialog doesn't popup unless you tell it to.
Moving to our GUI forum.