It's not a secret anymore!
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 Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » I/O and Streams
Bookmark "File Searching" Watch "File Searching" New topic

File Searching

Faye Abdon

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

Joined: Dec 11, 2004
Posts: 13410

Read all the methods of the object.
[ 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

Joined: Mar 06, 2001
Posts: 13459

Moving to the I/O and Streams forum.

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
I agree. Here's the link:
subject: File Searching
It's not a secret anymore!