aspose file tools*
The moose likes I/O and Streams and the fly likes File Searching Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "File Searching" Watch "File Searching" New topic
Author

File Searching

Faye Abdon
Greenhorn

Joined: Nov 14, 2005
Posts: 3
Hi! If anyone could help me with this, it would be much appreciated. How can i know the number of files with .txt extension existing in my directory? I tried using FileReader but it only reads one specific file. Please help.
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Read all the methods of the java.io.File object.
http://java.sun.com/j2se/1.5.0/docs/api/java/io/File.html
[ November 18, 2005: Message edited by: Ben Souther ]

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

Moving to the I/O and Streams forum.

Dave
payal agrawal
Ranch Hand

Joined: Oct 11, 2005
Posts: 44
Lok at the URL below.

How to get the list of specific file types in a directory
http://www.java-tips.org/content/view/599/2/
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: File Searching