Crash Recovery

Perhaps the most common way to find mistakes in programs is to crash them. For example, you might press the Run button, interact with your program a bit, and then hear a number of beeps until a dialog box appears displaying something like RTE-16: Attempted to divide by zero? What should you do?

Finding the mistakes

Try these steps when you see an error message.

Note the message in the dialog box. It will give you some idea of what went wrong.
  1. Press the OK.
  2. A Call Stack dialog box will appear, giving you a backtrace, showing what routines were called when the error occurred.
  3. If the bad code is in the module that you're editing, the Editor window will appear.
  4. The offending line of BASIC code will be highlighted in blue to show that execution is paused on that line.
  5. If there is a breakpoint set on that line, it will be highlighted in purple.
  6. Try to determine the problem by examining the BASIC code. You may also examine the values of your variables for clues about why the crash happened when it did.
  7. Once you've figured out what the problem is, you can either press the Continue button to skip the offending statement and attempt to continue executing the program, or press the Stop button so that you'll be able to make the necessary changes to your program.