The code in post#1 was having the problem. You need to find out where the program was looking for the file referenced there:
FileInputStream file = new FileInputStream("class.dat");
You want to...
Type: Posts; User: Norm
The code in post#1 was having the problem. You need to find out where the program was looking for the file referenced there:
FileInputStream file = new FileInputStream("class.dat");
You want to...
Something like this:
File aFile = new File<THEPathHERE>); // create a File object
System.out.println("an ID "+ aFile.getabolutepath()); // print its absolute path
check the spelling.
Create a File object using the filename and print its absolute path to see where the program is looking for the file.