Sent: Mittwoch, 11. März 2009 04:44
I just created a test class "ZTEST" in Q2Q, implemented both methods according to the document,
and I also do the needed configuration in tcode SCOT
And I write a report in Q2Q named ZOUTPUT1 to send a email ( attached with one PDF which can be uploaded in the report ) to my email address: jerry.wang@sap.com.
After I run the report, I did successfully get the email with PDF attached, but neither ZTESTIF_INBOUND_EXIT_BCSCREATE_INSTANCE nor IF_INBOUND_EXIT_BCS~PROCESS_INBOUND is called although the class is registered to my email address.
Why it is not called when email is received? Because I also find some SRM class in SCOT, so I guess the system should be working well.
There's a special way to debug these SAPConnect inbound processes and if you do not follow it you can not stop with a "normal" breakpoint, that you set before sending the mail.
Do the following instead
go to transaction SCOT enter 'dbg+' into the transaction field and press enter -> inbound process debugging is started
send the mail (in your case by starting your report)
go to transaction sm50 and search for the waiting process in class CL_SMTP_EXT_SAPCONNECT========CP to debug it (mark it and navigate to administration > program > debugging)
debugger opens and you can set breakpoint in your class, leave the endless loop by setting cursor to line 54 and press Shift+F12, let the debugger run with F8 and you will stop next in you class
debug whatever you want :)
!!! After finishing you have to stop inbound process debugging in scot again by entering 'dbg-' and pressing enter !!! (this can also already be done when you found your process in step 3)