Hello,
I have a scenarion where the JCO connection Exeption has to be trapped and dispaly the user defined error message...
How to trap it..
I used the following the code, but it doesn't work.
catch (JCO.AbapException ex) {
if (ex.getKey().equalsIgnoreCase("NOT_FOUND")) {
messageMgr.reportException("Dictionary structure/table not found.",false);
System.exit(1);
}else {
messageMgr.reportException(ex.getMessage(),false);
System.exit(1);
}
}catch (JCO.Exception ex) {
ex.printStackTrace();
System.exit(1);
}