Getting Error while calling XBP Function Module via SAP.net connector

SAPSAP .NET

Note that you need to execute function call in a single session so you have to wrap your logic into JCoContext. Try using below method:

try {
   JCoContext.begin(destination);
   try {
      // your function calls here
      // probably bapiTransactionCommit.execute(destination);
   } catch(AbapException ex) {
      // probably bapiTransactionRollback.execute(destination);
   }
} catch(JCoException ex) {
   [...]
} finally {
   JCoContext.end(destination);
}
raja
Published on 19-Dec-2017 11:35:30
Advertisements