We are using the BADI BBP_TARGET_OBJTYPE to determine a PR or PO and change the doc type if PR is determined.
PR/PO is determined correctly but when we tried to assign new doc type for PR getting error "BBP_BD 002: An Exception occured" .
Below is the code.
IF wa_item-catalogid IS INITIAL OR wa_item-catalogid CO space
wa_item-pack_objtype = 'BUS2105'. "PR
wa_item-be_doc_type = 'ECPR'
wa_item-pack_objtype = 'BUS2012'. "PO
MODIFY ct_item FROM wa_item TRANSPORTING pack_objtype.
Can any one tell is this correct or do we need to modify anything?
Thanks in advance,
Edited by: Jagdish Reddy on Aug 17, 2008 3:47 PM