2005 Sep 09 12:21 AM
We have upgraded from 4.5B to 4.7. Previously the attachment was emailed with the form name e.g form.pdf. Since the upgrade the name of the attachment is the same as the email description. This is causing a problem since the recipient's firewall does not accept the new file name. Any suggestions on how to send with a file name different from the object description.
Thanks,
Jill
2005 Sep 09 2:54 AM
Hi ,
The name of email attachment depends on how it is created and sent. CAn you give more details as whether these are custom programs or standard programs .
We faced the same issue and had to fix case by case.
Cheers.
2005 Sep 09 4:13 AM
please post the code of FM you are using to send email.
recently i corrected same problem.
i tell you best way to solve this problem.
In 4.7 , goto se37, enter this FM, and click where used list button. then look into various SAP program, there is a new parameter added in Export. just add this one to your code. and it will work fine.
if you need more help , post this FM's CODING .
regards
2005 Sep 12 12:37 AM
Using standard SAP function modules
The relevant code is as follows
...
CLEAR I_ITCPO.
I_ITCPO-TDCOPIES = 1.
I_ITCPO-TDNOPREV = ' '.
I_ITCPO-TDNEWID = 'X'.
I_ITCPO-TDDATASET = 'Agency'.
I_ITCPO-TDIMMED = 'X'.
I_ITCPO-TDLIFETIME = 8.
I_ITCPO-TDTELELAND = ADRC-COUNTRY.
I_ITCPO-TDCOVER = ' '.
I_ITCPO-TDTITLE = EMAIL_TITLE.
CALL FUNCTION 'ADDR_GET_NEXT_COMM_TYPE'
EXPORTING
STRATEGY = 'ZINT'
ADDRESS_NUMBER = ADR6-ADDRNUMBER
PERSON_NUMBER = ADR6-PERSNUMBER
IMPORTING
COMM_TYPE = LVS_COMM_TYPE
COMM_VALUES = LVS_COMM_VALUES
EXCEPTIONS
ADDRESS_NOT_EXIST = 1
PERSON_NOT_EXIST = 2
NO_COMM_TYPE_FOUND = 3
INTERNAL_ERROR = 4
PARAMETER_ERROR = 5
OTHERS = 6.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
convert communication data
MOVE-CORRESPONDING I_ITCPO TO LVS_SNAST.
MOVE SY-REPID TO LVF_PROGRAM.
CALL FUNCTION 'CONVERT_COMM_TYPE_DATA'
EXPORTING
PI_COMM_TYPE = LVS_COMM_TYPE
PI_COMM_VALUES = LVS_COMM_VALUES
PI_COUNTRY = 'AU'
PI_REPID = LVF_PROGRAM
PI_SNAST = LVS_SNAST
IMPORTING
PE_ITCPO = LVS_ITCPO
PE_DEVICE = LVF_DEVICE
PE_MAIL_RECIPIENT = LVS_RECIPIENT
PE_MAIL_SENDER = LVS_SENDER
EXCEPTIONS
COMM_TYPE_NOT_SUPPORTED = 1
RECIPIENT_CREATION_FAILED = 2
SENDER_CREATION_FAILED = 3
OTHERS = 4.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'OPEN_FORM'
EXPORTING
DEVICE = 'MAIL'
DIALOG = ' '
FORM = SS_FORM
MAIL_SENDER = LVS_SENDER
MAIL_RECIPIENT = LVS_RECIPIENT
OPTIONS = I_ITCPO
EXCEPTIONS
CANCELED = 1
DEVICE = 2
FORM = 3
OPTIONS = 4
UNCLOSED = 5
MAIL_OPTIONS = 6
ARCHIVE_ERROR = 7
MORE_PARAMS_NEEDED_IN_BATCH = 8
OTHERS = 9.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
...
Prior to the upgrade the variable SS_FORM was the name of the attachment. Post upgrade the name of the attachment is the same as the email title (EMAIL_TITLE).
Hope you can help.
Thanks,
Jill
2005 Sep 12 7:27 AM
Hi,
Just check out think link:
http://www.sapdevelopment.co.uk/reporting/rep_spooltopdf.htm
Best Regards,
Anjali
2005 Sep 12 8:25 AM
Thanks Anjali.
However,
As you can see from my code I am using the OPEN_FORM (DEVICE = MAIL) to send the form, not the function module SO_SEND.... Therein lies my problem. How can I specify the name of the attachment, different from the email title.