I\'ve seen that this is possible in other types of dialog windows such as \"showConfirmDialog\", where one can specify the amount of buttons and their names; but is this sam
Try:
JOptionPane.showMessageDialog(frame, "Eggs are not supposed to be green.");
I found in here