wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes read string from textfile into array Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "read string from textfile into array" Watch "read string from textfile into array" New topic
Author

read string from textfile into array

Tony Smith
Ranch Hand

Joined: Jul 07, 2007
Posts: 229
Hi, if a have one line of text in a file, what would be the easiest way to read that line of text into array if I don't know the size of the text?
marc weber
Sheriff

Joined: Aug 31, 2004
Posts: 11343

The nextLine() method in java.util.Scanner?


"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: read string from textfile into array
 
Similar Threads
I/O
total number of rows to array
Reading characters from a file into an array
Searching for string usign JSTL
Lookahead with Java