Travel of Software Developer

A Java Developer

27.7.10

Displaying Only Directories in a File Chooser Dialog

 

JFileChooser fileChooser = new JFileChooser(file); fileChooser.setFileSelectionMode(JFileChooser.DIRECTORIES_ONLY);

 

Related examples

Adding a Filter to a File Chooser Dialog

Copying the Filename Path from a JFileChooser Dialog to the Clipboard

Creating a JFileChooser Dialog

Determining If the Approve or Cancel Button Was Clicked in a JFileChooser Dialog

Getting and Setting the Current Directory of a JFileChooser Dialog

Getting and Setting the Selected File of a JFileChooser Dialog

Getting the File-Type Name of a File

http://www.exampledepot.com/egs/javax.swing.filechooser/DirOnly.html

Jeff at 20:12:00
Share

No comments:

Post a Comment

‹
›
Home
View web version

Contributors

  • Jeff
  • Unknown
  • Unknown
Powered by Blogger.