Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- try (FileInputStream fis = new FileInputStream(newFile)) {
- System.out.println("fis");
- System.out.println(fis.read()); //prints 77
- int content;
- while ((content = fis.read()) != -1) {
- System.out.print((char) content);
- }
- fis.close();
- }
- catch (IOException e){
- e.printStackTrace();
- }
Advertisement
Add Comment
Please, Sign In to add comment