try { String fileName = "adat.txt"; Reader r = null; try { InputStream in = new FileInputStream(fileName); //US-ASCII r = new InputStreamReader(in, "UTF-8"); } catch(UnsupportedEncodingException e) {} Scanner nFile = new Scanner(r); while(nFile.hasNextLine()) { String str = nFile.nextLine(); System.out.println(str); } nFile.close(); } catch(FileNotFoundException e) { System.err.println("Hiba a fájlból olvasás során"); }