I am using a JFileChooser and I am trying to validate some user input. When the user clicks a file to save (I am using the showSaveDialog() method) I check to see if the file already exists using the exists() method. The problem I am having is if I show a JOptionPane to the user telling them that the file already exists the JFileChooser disapears. I do not want the JFileChooser to disapear I want to display the JOptionPane ontop of the JFileChooser. I want the JFileChooser to disappear if the user clicks Yes on the JOptionPane.
Thanks for all your help!