There are also many other tutorials on the internet dealing with just about every aspect of java.
There are a number of ways to do what you want to do but one way is to use a BufferedReader wrapped around a FileReader. Read a character at a time and append to a StringBuffer. Finally if you want it as a string then use the StringBuffer.toString() method.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.