Nadiatjie wrote:
firstly I have an error and I don't know what it means:
java.lang.NoClassDefFoundError: toets
Caused by: java.lang.ClassNotFoundException: toets
It would help to know a bit more about your environment. Are you getting this error when you're running you program or before it even starts? This error means that Java can't find a class that it is looking for. This can vary from when it first starts up to while it is running.
Nadiatjie wrote:
secondly I don't know how to save data on the computer after it has been entered, say if I used a JOptionPane and this person entered their name and played a game and won, how and where can I save this information so that it will still be found the next time they log on?
The data should probably be saved to a file. You can save the data with something likelike:
and read it back with something like:
Create a file at a known place, for example in the users home directory (retrieved from System.getProperty( "user.home" )) So your file name might be:
This gets the home directory of the user, a string that is the "file separator" which would be "/" on Unix based O/S's and "\" on Windows, and appends a file name.