Runtime Errors

Runtime errors occur at runtime when the code executes. Runtime errors can include errors that occur because of something that it not allowed or supposed to happen. For example, a line of code that tries to assign a variable of one data type to an incompatible value could result in a runtime error. The example in Figure 2.32 runs the CalculateSalesTax function and passes string values as parameters, instead of the required currency and double values. The result is a runtime error, which in this example is a Type Mismatch error.

jre 2.32
0 0

Post a comment