Your last post: with 2 new Action Listener
was confusing.
Type: Posts; User: Norm
Your last post: with 2 new Action Listener
was confusing.
I'm sure there are several ways you could do it. More ActionListeners sounds more complicated than the way I did it.
No, that is not I meant. I meant to change the listener to something like this so when the button was pressed, setVisible(false) would execute and the window with the button would disappear.
...
What happens when you call setVisible(false) for a visible window?
Change your posted code to call setVisible(false) for the currently visible window. Don't do anything else, just call that...
Please explain what happens/
if(str == "OK")
You should use the equals() method to compare the contents of Strings, not the == operator.