I am attempting to make a program, and it involves a JFileChooser. I am trying to make it so that the users can only pick .zip files. My code is
JFileChooser finder = new JFileChooser();
finder.setFileFilter(new FileNameExtensionFilter(null, ".zip"));
This seems to me like it would run fine, however when I go to a folder with a .zip file, the .zip files are gray, and I can't choose them. How do I fix this? Also, as a side question, how do I get rid of the "All Files" option in the JFileChooser window?