Created
October 25, 2012 06:25
-
-
Save liudong/3950833 to your computer and use it in GitHub Desktop.
Java: List Files in Folder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File folder = new File(FOLDER); | |
if ( folder.isDirectory() == true ) { | |
File[] docList = folder.listFiles(); | |
if ( docList != null ) { | |
for ( File doc : docList ) { | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment