Hi Folks,
I have a tricky issue.
We have configured Shipping(V2) output type ZOUT with Custom program ZCUSTOM_PROG.
In the custom program ZCUSTOM_PROG: we are using BAPI BAPI_BILLINGDOC_CREATEMULTIPLE in background task.
CALL FUNCTION 'BAPI_BILLINGDOC_CREATEMULTIPLE' in background task
TABLES
billingdatain = lt_billing
return = lt_return
success = lt_success.
Testing process: in t.code: VL02N, we have added output type ZOUT on the delivery header, saved.
now we have done the PGI for this OBD.
Issue: When it process PGI, I could somehow in debugging the custom program, but here BAPI is not returning either error message or success message, at this point of time the invoice is not created and not available in VBFA table, after completion of the process(F8), I could see the invoice created and the Invoice document (M) is available in VBFA.
But how to handle my custom program while PGI process invoice will be created or not???
NOTE: this is background process so I can't use the BAPI_Transactional_commit or commit work after the BAPI.
Any suggestion, it will really help.
Best Regards
Naresh Kumar.