How to read text files in Java...
i want to write a java program that reads atext file or ms word file
and generates a summary of that file.
I mean a kind of abstract of the file.
What shld i use to achieve this problem?
please help me out.
Re: How to read text files in Java...
"Billy" <email@example.com> wrote:
> i want to write a java program that reads atext file or ms word file
>and generates a summary of that file.
>I mean a kind of abstract of the file.
>What shld i use to achieve this problem?
>please help me out.
There is not a way, that I am aware of, to read an MS Word document in Java.
MS Word is encoded in a proprietary format that Java cannot easily navigate.
Reading a text file, on the other hand, can be handled in Java. Want you
want are the classes made available in the java.io package. You will want
to open a stream to the document, read the contents (or a portion of them)
into your program, and then perform whatever processing your program requires.
I have provided three links that I think you will find helpful:
If you have any other questions, feel free to post another question.
DevX Java Pro
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL