skip to main content

Converting Java Source Code to Object-oriented COBOL : Error Handling

Error Handling
Java statements are usually bracketed in try/catch blocks, so the program can intercept and handle exception conditions. Some methods require a try/catch block and the compiler will return an error if one is not included. In any case, using try/catch is the preferred and recommended practice.
COBOL and Java have similar try/catch syntax.
The Java syntax is:
The COBOL syntax is:

Copyright (c) 2017 Veryant
Contact us
Please share your comments on this manual or on any
Veryant product documentation with the email button at the top left