Customer Statement BTE issue with Email & Spool generation
I have used BTE 2310 for triggering the email for Customer statement.
It is working fine.
Issue is....when there is an email maintained in the customer master, it is triggering email but no spool is generated.
And if there is no email maintained in customer master, spool is getting generated... (off course no email)
We want both the functionality i.e. spool should be there as well email should also trigger.
We have maintained following code in the BTE FM..
IF i_kna1 IS NOT INITIAL.
CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
input = i_kna1-adrnr
output = lv_addrnumber.
SELECT SINGLE smtp_addr
WHERE addrnumber = lv_addrnumber.
IF lv_email IS NOT INITIAL.
c_finaa-intad = lv_email.
c_finaa-nacha = 'I'.
c_finaa-mail_body_text = 'ZPB_CUST_EMAIL_BODY_TXT'. "mail body
c_itcpo-tdcovtitle = 'Customer Statement'. "mail subject
Please suggest if i am missing something.
Thanks in advance.