2017 Jun 23 10:42 AM - edited 2024 Feb 03 10:31 PM
Hi Guys,
We are in the process of migrating our webdynpro java application from 7.0 to 7.5. We have migrated them successfully. Also migrated the ARFC function module to ARFC2 function modules as well.
Now while executing the function module, the RFC in the backend is raising some exception. I need to capture the exception text in webdynpro java. In previous versions it is working fine. But once migrated, I am not able to get the exception text. Instead it gives "Typed Model Execution failed. See nested exception for details."
Anything has changed in ARFC2 that we need to adapt here. It works fine in 7.0 though.
Below is the code I am using.
try{
// Model execution code here
}
catch (Exception e){
messageMgr.reportException(e.getMessage());
}
Regards,
Madhu
Request clarification before answering.
Hi Madhu,
We recently faced the same issue and I hope this helps you and others.
In order to return the exception raised rather than a generic ARFC2 exception we used the following:
catch (ARFC2ModelExecuteException e){
String s = e.getNestedLocalizedMessage();
messageMgr.reportException(s.substring(s.lastIndexOf(':') + 1).trim());
}
Regards,
Patrick.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
76 | |
30 | |
10 | |
8 | |
8 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.