JFileChooser - multiple file filters?

Posted by waitinforatrain on Stack Overflow See other posts from Stack Overflow or by waitinforatrain
Published on 2010-03-15T20:24:07Z Indexed on 2010/03/15 20:29 UTC
Read the original article Hit count: 387

Filed under:
|
|
|

Hi guys,

I have a question about the JFileChooser in Swing. I'm trying to get multiple file extensions in the drop-down box, but have no idea how to do it.

There is the method

extFilter = FileNameExtensionFilter(description, extensions);

that I can then use by writing

fileChooser.setFileFilter(extFilter);

however, as you can see, this only supports one option in the drop-down list. How do I add more?

© Stack Overflow or respective owner

Related posts about java

Related posts about jfilechooser