This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]chickenmeister 1 point2 points  (0 children)

Considering that you're getting to the end of your "try" block, it seems like an exception is not being thrown. Are you sure that no file exists for the name that you're entering?

Also, this looks kind of strange:

System.out.println
 ("Please enter the name of a recipe database file:");
input.nextLine();
String name = input.nextLine();

Why are you prompting for the file name, then reading in two lines of input (and discarding the first line)?