Error Handling

In general, the HACL indicates errors to the application by the throwing ECLErr objects. To catch errors, the application should enclose calls to the HACL objects in a try/catch block such as:
try {
       int pos = ps.ConvertRowColToPos(row, col);

       //...possibly more references to HACL objects...

    } catch (ECLErr err) {
       System.out.println("ECL Error!  " + err.GetMsgText());
    }
 

When an HACL error is detected, the application can call methods of the ECLErr object to determine the exact cause of the error. The ECLErr object can also be called to construct a complete language-sensitive error message.