I also remember my VB days, how not writing error handling code would result in the entire app showing a runtime error dialog and then terminating. It was easy to fall into this trap too when writing code. Lots of VB apps I used worked fine in normal circumstances but failed miserable when, for example, a file could not be read from disk.
In Java you will always be told by the compiler when you don't handle errors when dealing with files thanks to checked exceptions. Yes, it is more work on the developer's part, but that bit of extra work is worth it since apps will be more reliable. |