I am trying to create a message with a Yes or No button. Then a window will appear with a certain message that depends on if the user clicked Yes or No.
Here is m
"if(true)" will always be true and it will never make it to the else. If you want it to work correctly you have to do this:
int reply = JOptionPane.showConfirmDialog(null, message, title, JOptionPane.YES_NO_OPTION);
if (reply == JOptionPane.YES_OPTION) {
JOptionPane.showMessageDialog(null, "HELLO");
} else {
JOptionPane.showMessageDialog(null, "GOODBYE");
System.exit(0);
}