08-21-2007 6:40 AM
Hi Experts,
I've a doubt in Error Handling.While i am excuting the BDC Call Transaction Program How to check Error Handling in foreground.
Its an urjent issue.Please send me the solution as early as possible.
Thanks in advance.
Regards,
Rekha
08-21-2007 6:43 AM
08-21-2007 6:45 AM
Hi,
after Call transaction..........................statement , check sy-subrc i.e
data: msgtab type standard table of bdcmsgcoll .
call transaction tcode .......mesaages into msgtab.
if sy-subrc <> 0.
call function 'FORMAT_MESSAGE'.----> this will craete message
.........
,,,,,,,,,
fill the messages into another internal table which should be displayed .
endif.
Display the interanl table which is filled with messages.
Rvert back if any issues,
Reward with poinst if helpful.
Regards,
Naveen
08-21-2007 6:45 AM
When u run the BDC in foreground u can just change the errorneous data and no error handling is required as such..and u can only get success messages in the end in
BDCMSGCOLL itab.
try it with breakpoint in itab_msg.
call transaction 'MI01' using itab_bdcdata mode 'A' MESSAGES INTO
ITAB_msg.
loop at itab_msg where msgtyp = 'S'.
break-point.
message i010(zmgs) with itab_msg-MSGV1.
docno = itab_msg-msgv1.
endloop
Message was edited by:
Madan Gopal Sharma
Message was edited by:
Madan Gopal Sharma
08-21-2007 6:48 AM
hi Rekha,
use BDCMSGCOLL to track the errors in BDC .
Reward points if useful.
Cheers,
Chandra