
796 CHAPTER 11 Exceptions and Input/Output Operations
When you call animate, the window will display the current
transaction graphically. It will also display the transaction
amount (red if negative, blue if positive) and the current check-
book balance (in black). By adding the previous checkbook bal-
ance to the current transaction amount, you will be able to
compute the current checkbook balance and check that your pro-
gram is correct.
■
Stop reading from the file when you reach the end of the file. You
will need to set up a catch block to handle the EOFException that
occurs when the end of the file is reached.
■
Display the ending balance in a dialog ...