Email excel attachment
I am sending an email with an excel attachment using fm SO_NEW_DOCUMENT_ATT_SEND_API1. All is well except that the first column of the excel document displys a load of blank spaces in front of the data item. Is there any way of cutting out the blank spaces?
Code is as follows:
Populate the email header
CONCATENATE text-m09 l_pltxt INTO docdata-obj_descr.
docdata-obj_name = text-m11.
Populate the body of the mail
MOVE text-m10 TO objtxt.
APPEND objtxt.
DESCRIBE TABLE objtxt LINES tab_lines.
READ TABLE objtxt INDEX tab_lines.
Size of the document in bytes. The calculation is
Length of last line + number of remaining lines * 255
docdata-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objtxt ).
CLEAR objpack-transf_bin.
objpack-head_start = 1.
objpack-head_num = 0.
objpack-body_start = 1.
objpack-body_num = tab_lines.
objpack-doc_type = 'RAW'.
APPEND objpack.
Get end of line character
l_eol = cl_abap_char_utilities=>newline.
Set up attachment
Column headers
CONCATENATE 'Requested by'
'Serial Number'
'Part Number'
'Inst.or Dism.'
'Mvmnt.To(Sup.Equip.)'
'Mvmnt.To(Func.Loc.)'
'Mvmnt.Date'
'Posn'
'Start Date'
l_eol
INTO objbin SEPARATED BY ','.
APPEND objbin.
CLEAR objbin.
Lines
LOOP AT it_equipment.
CONCATENATE sy-uname
it_equipment-sernr
zdbmatl-matnr
it_equipment-iord
it_equipment-equnr
it_equipment-tplnr
it_equipment-move_date
it_equipment-pors
it_equipment-start_date
l_eol
INTO objbin SEPARATED BY ','.
APPEND objbin.
CLEAR objbin.
ENDLOOP.
att_type = 'CSV'.
DESCRIBE TABLE objbin LINES tab_lines.
READ TABLE objbin INDEX tab_lines.
Size of the document in bytes.The calculation is
Length of last line + number of remaining lines * 255
objpack-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( objbin ).
objpack-transf_bin = 'X'.
objpack-head_start = 1.
objpack-head_num = 0.
objpack-body_start = 1.
objpack-body_num = tab_lines.
objpack-doc_type = att_type.
objpack-obj_name = 'ATTACHMENT'.
CONCATENATE text-m09
l_pltxt
INTO objpack-obj_descr SEPARATED BY space.
APPEND objpack.
CLEAR objpack.
reclist-receiver = '[email protected]'.
reclist-rec_type = 'U'.
APPEND reclist.
Send mail
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = docdata
put_in_outbox = 'X'
TABLES
packing_list = objpack
object_header = objhead
contents_bin = objbin
contents_txt = objtxt
receivers = reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.
COMMIT WORK.
Hi
Please see the link below
It will definately satisfy your requirement.
Re: FI docu
<b>Mark if helpful</b>
Regards
Tushar
Message was edited by:
Tushar Mundlik
Similar Messages
-
Email Excel attachment with a BOLD row
hi!
My requirement is that data in an internal table should be sent as an attachment in an email. There are a few records in the internal table which needs to be in bold(i have the logic to figure out whichones). I am using the below FM .
CALL FUNCTION 'SO_OBJECT_SEND'
EXPORTING
object_hd_change = wa_object_hd
object_type = 'RAW'
TABLES
objcont = i_text
receivers = i_recv
packing_list = i_packing_list
att_cont = i_att
Does any body have any idea how to bold a few records in the excel attachment?
I appreciate your suggestions.
Thanks,
manasa
Message was edited by:
manasaHi Manasa,
The Code below is for sending Excel attachment in email. Not sure for BOLD...
You can copy and paste the following codes and execute..
Hope this will help you..
TYPE-POOLS: truxs.
DATA t5 LIKE t005t OCCURS 0 WITH HEADER LINE.
START-OF-SELECTION.
SELECT * INTO TABLE t5
FROM t005t
WHERE spras = sy-langu.
DATA wa_data TYPE truxs_t_text_data.
CALL FUNCTION 'SAP_CONVERT_TO_TXT_FORMAT'
EXPORTING
i_line_header = 'X'
TABLES
i_tab_sap_data = t5
CHANGING
i_tab_converted_data = wa_data
EXCEPTIONS
conversion_failed = 1
OTHERS = 2.
DATA stmp(4096) TYPE c.
DATA itmp TYPE i.
LOOP AT wa_data INTO stmp.
itmp = STRLEN( stmp ).
stmp+itmp = cl_abap_char_utilities=>cr_lf.
MODIFY wa_data FROM stmp.
ENDLOOP.
PERFORM send_email.
*& Form send_email
FORM send_email .
DATA docs LIKE docs OCCURS 0 WITH HEADER LINE.
DATA excelsize TYPE i.
DATA excel LIKE solisti1 OCCURS 0 WITH HEADER LINE.
DATA doc LIKE sodocchgi1.
DATA excelln TYPE i.
DATA int_objpack LIKE sopcklsti1 OCCURS 2 WITH HEADER LINE.
DATA int_objhead LIKE solisti1 OCCURS 2 WITH HEADER LINE.
DATA int_objtext LIKE solisti1 OCCURS 0 WITH HEADER LINE.
DATA int_reclist LIKE somlreci1 OCCURS 1 WITH HEADER LINE.
DATA bodyln LIKE sy-tabix.
DATA output_data TYPE ssfcrescl.
excel[] = wa_data[].
excel table sizes
DESCRIBE TABLE excel LINES excelln.
Body Email
int_objtext-line = 'Test Body'.
APPEND int_objtext.
DESCRIBE TABLE int_objtext LINES bodyln.
READ TABLE int_objtext INDEX bodyln.
CLEAR doc.
doc-doc_size = ( bodyln - 1 ) * 255 + STRLEN( int_objtext ).
doc-obj_name = ' '.
doc-sensitivty = 'P'.
doc-proc_syst = sy-sysid.
doc-proc_clint = sy-mandt.
CLEAR: int_objpack, int_objpack[].
int_objpack-transf_bin = ' '.
int_objpack-head_start = 1.
int_objpack-head_num = 0.
int_objpack-body_start = 1.
int_objpack-body_num = bodyln.
int_objpack-doc_type = 'RAW'.
int_objpack-obj_descr = 'Test'.
APPEND int_objpack.
CLEAR: int_objhead, int_objhead[].
int_objhead = 'Attachment'.
APPEND int_objhead.
int_objpack-transf_bin = 'X'.
int_objpack-head_start = 1.
int_objpack-head_num = 0.
int_objpack-body_start = 1.
int_objpack-body_num = excelln.
int_objpack-doc_size = excelsize.
int_objpack-doc_type = 'XLS'.
int_objpack-obj_name = 'excel'.
int_objpack-obj_descr = 'test.xls'. "File name
APPEND int_objpack.
Set Receiver
int_reclist-receiver = 'SAPUSER'.
int_reclist-rec_type = 'B'.
int_reclist-notif_del = 'X'.
int_reclist-notif_read = 'X'.
int_reclist-notif_ndel = 'X'.
int_reclist-express = 'X'.
APPEND int_reclist.
doc-obj_descr = 'Report in Excel'.
Sending Email
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = doc
put_in_outbox = 'X'
commit_work = 'X'
TABLES
packing_list = int_objpack
object_header = int_objhead
contents_bin = excel
contents_txt = int_objtext "Body
receivers = int_reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.
ENDFORM. " send_email
Note:
- If you are using FM SAP_CONVERT_TO_TXT_FORMAT you will not be able to execute this program in the background.
- dont forget to change 'SAPUSER' to your SAP user ID
- you can check the email by using tcode 'SBWP'.
Reward points if this Helps.
Manish -
Hi All,
My requirement is to convert the alv output to an excel and send it to email in background processing.
Am creating the headers through the field cat headings as the headings are dynamic.
And the item data through the output internal table of ALV.
My issue is always the second row's first column is taking spaces in the start because of this the data starts getting truncated.
Am using a tab delimter to seprate 2 fields and at the end of a row am using line breaker cl_abap_char_utilities=>cr_lf.
the below is how am filling the packing lists.
Fill Packing List For body
lw_packing_list-transf_bin = space.
lw_packing_list-head_start = 1.
lw_packing_list-head_num = 0.
lw_packing_list-body_start = 1.
DESCRIBE TABLE lt_message LINES lw_packing_list-body_num.
lw_packing_list-doc_type = 'RAW'.
APPEND lw_packing_list TO lt_packing_list.
clear lw_packing_list.
Fill the fields of the packing_list for creating the attachment:
lw_packing_list-transf_bin = lc_x.
lw_packing_list-head_start = 1.
lw_packing_list-head_num = 1.
lw_packing_list-body_start = 1.
DESCRIBE TABLE t_attach LINES lw_packing_list-body_num.
lw_packing_list-doc_type = lv_format.
lw_packing_list-obj_descr = lv_attdesc.
lw_packing_list-doc_size = lw_packing_list-body_num * 255.
APPEND lw_packing_list TO lt_packing_list.
Fill the mail recipient list
lw_reclist-rec_type = 'U'.
lw_reclist-com_type = 'INT'.
LOOP AT t_recipient_list INTO w_recipient_list.
lw_reclist-receiver = w_recipient_list-ZSMTP_ADR.
APPEND lw_reclist TO lt_reclist.
ENDLOOP.
I have surfed the google and SDN but could not find any solution to my problem Please help guys..Hi,
go to se38-->enter program name BCS_EXAMPLE_7
and see the sample code to send XLS attachment...
in this program it shows how to send the internal table or ALV report data into excel mail attachment
Prabhudas -
Email Excel attachement showing dollar amount instead of date.
Hi,
I emailed an Excel (.xlsx) file from my pc to two people. They both opened the attachment on their iPads from mail. One person is seing the only date column as a dollar amount with a dollar sign. The other person is showing the column correctly. I looked for any setting that could cause this, but I cannot see anything.
Any suggestions would greatly be appreciated.
Thank you.Hi SZ,
you can configure what properties are showed for resources within the collection or the resource renderer. Check this out and around: http://help.sap.com/saphelp_ep50sp5/helpdata/en/50/041142e862654ca98ced1607386c9c/frameset.htm (especially "Visible Properties"). Take some time to understand the mechanisms...
> We are using EP5
Ah, <i>you</i> are the last one
Hope it helps
Detlev
PS: Please consider rewarding points for helpful answers on SDN. Thanks in advance! -
Issue in Sending email with EXCEL attachment
Hi,
Im using the FM SO_NEW_DOCUMENT_ATT_SEND_API1 for sending emails to a list of recipients with an excel attachment. In the attachment data, as the field length is 255 for the structure SOLISTI1, for the records having more than 255 characters, data is being truncated. I did a search in this forum and done some changes , still it is not working properly.
I have used SCMS_TEXT_TO_XSTRING, SCMS_XSTRING_TO_BINARY FMs for converting the data to hexa format. This case, records having more than 255 are displayed properly in the attachment, but there are blank lines inserted between two records.
Please suggest me to resolve this isssue.
Thanks in advance.
JayashreeHi Jayashree,
you might want to check out the example link by Saso in his post Send external email from within ABAP program to xls.
For the rest I can only guess that there might be some issues with the format you use for Excel. In case of empty lines and using a text format for Excel the issue is in most cases that there are too many carriage return line feeds in the text fiel (cl_abap_char_utilities=>cr_lf).
Hope that helps.
Best Regards
Michael -
How to send pdf or excel attachment as saved alv layout in email
Hi Guru,
I am developing a report in which, i am sending report as excel attachment after clicking a button on top of alv grid, and pdf attachment after clicking another button on top of alv grid. I am sending mail by two ways they are:
1) I am populating my internal table value in separate internal table and converting that to string and sending email as excel attachment.
2) And am converting report as spooljob, and using abapspool 2 pdf function module i am converting spool to pdf, after that am send that pdf as mail attachment.
Now my requirement is i need to send email attachment as layout which is displayed in the alv screen, even i hide a column and change the layout it is going with all the columns. What should i do for this problem.
Regards,
RithikaHi,
Check if the below steps will solve the problem.
* Get the run time ALV layout (field catalog) using the below method.
data: r_grid TYPE REF TO cl_gui_alv_grid.
CALL METHOD r_grid->get_frontend_fieldcatalog
IMPORTING
et_fieldcatalog = t_fcat.
* Adjust the download table according to t_fcat. -
EXCEL attachment as EMAIL to USER - When USER executes REPORT in BACKGROUND
Hi Friends,
I have 10 records in Internal Table. In BACK GROUND execution, I have to send this 10 records as EXCEL attachment through EMAIL to the USER who executed in background.
How to do this? Thanks in advance.
Regards,
Viji.hi,
the following excerpt converts to excel:
REPORT ZEX_DATATOEXCEL .
Parameters: P_file like RLGRAP-FILENAME.
data : begin of int_head occurs 0,
Filed1(20) type c, " Header Data
end of int_head.
data : begin of int_data occurs 0,
Field1(20) type c, " Data
Field2(20) type c,
Field3(20) type c,
Field4(20) type c,
end of int_data.
int_head-Filed1 = 'Sales Ord'.
APPEND int_head.
CLEAR int_head.
int_head-Filed1 = 'Sold-to-Party'.
APPEND int_head.
CLEAR int_head.
int_head-Filed1 = 'Purchase Ord'.
APPEND int_head.
CLEAR int_head.
int_head-Filed1 = 'Ship-to-Party'.
APPEND int_head.
CLEAR int_head.
int_data-field1 = '1JOHN'.
int_data-field2 = '2TOM'.
int_data-field3 = '3BRAD'.
int_data-field4 = '4PETER'.
Append int_data.
Clear int_data.
CALL FUNCTION 'MS_EXCEL_OLE_STANDARD_DAT'
EXPORTING
file_name = p_file " path offile where u need to download
* CREATE_PIVOT = 0
* DATA_SHEET_NAME = ' '
* PIVOT_SHEET_NAME = ' '
* PASSWORD = ' '
* PASSWORD_OPTION = 0
TABLES
* PIVOT_FIELD_TAB =
data_tab = int_data "internal table with data
fieldnames = int_head "internal table with header
EXCEPTIONS
file_not_exist = 1
filename_expected = 2
communication_error = 3
ole_object_method_error = 4
ole_object_property_error = 5
invalid_filename = 6
invalid_pivot_fields = 7
download_problem = 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.
got it from
http://abaplovers.blogspot.com/2008/05/abap-internal-table-to-excel-sheet.html.
then you can export to spool and mail it.
ags. -
Send Email with Excel attachment with formatting(bold, color) in Background
Hi,
I have requirement wherein I have to send an email with excel attachment with proper formatting of certain fields in the excel sheet like making it bold or setting different color. The data is available in an internal table. Just to to format it and send an email when the program is executed in background mode.
Any pointers on this would be highly appreciated!
Thanks,
Anil.I resolved my own problem using the BCS_EXAMPLE_7 program as sample.
-
Send email with excel attachment in outlook structure - SAP 6.0
Hello experts..
I need send a email with a excel attachment and use the signature in outlook to send.
The attachment will be create in the process of send email program.
Is it possible?
How can I created and attach in the same process?
How can I use the outlook strutucture to send a email?I resolved my own problem using the BCS_EXAMPLE_7 program as sample.
-
Facing problem in excel attachment in the Email
Hi,
I am facing one issue while sending an email with an excel attachment . In the excel attachment the actual number of line items are not displaying . For example if i have 4 rows in my internal table the excel shows only the first row of the internal table.
Can anybody suggest what is the issue.
Regards,
Ratheesh BSHi ,
Please find the code used.
WRITE: sy-datum TO l_date MM/DD/YY.
CONCATENATE text-014 "Enterprise workflow(s) are in ERROR status
l_date
INTO l_text
SEPARATED BY c_colon.
wa_doc_data-obj_langu = sy-langu.
wa_doc_data-obj_name = text-013. "SAPRPT
wa_doc_data-obj_descr = l_text.
wa_doc_data-sensitivty = c_false.
Fill the document data and get size of attachment
DESCRIBE TABLE i_attach LINES l_cnt.
READ TABLE i_attach INTO wa_attach INDEX l_cnt.
IF sy-subrc EQ 0.
l_size = STRLEN( wa_attach ).
l_docsize = ( ( l_cnt - 1 ) * c_length255 + l_size ).
wa_doc_data-doc_size = l_docsize.
wa_doc_data-obj_langu = sy-langu.
wa_doc_data-obj_name = text-013. "SAPRPT
wa_doc_data-obj_descr = l_text.
wa_doc_data-sensitivty = c_false.
ENDIF.
lt_attachment[] = i_attach[]." XLS attachment details
Describe the body of the message
CLEAR wa_packing_list.
REFRESH lt_packing_list.
wa_packing_list-transf_bin = space.
wa_packing_list-head_start = 1.
wa_packing_list-head_num = 0.
wa_packing_list-body_start = 1.
DESCRIBE TABLE lt_message LINES wa_packing_list-body_num .
wa_packing_list-doc_type = c_raw.
APPEND wa_packing_list TO lt_packing_list.
CLEAR wa_packing_list.
*l_docsize = 5000.
Create attachment notification
wa_packing_list-transf_bin = c_active.
wa_packing_list-head_start = 1.
wa_packing_list-head_num = 1.
wa_packing_list-body_start = 1.
DESCRIBE TABLE lt_attachment LINES wa_packing_list-body_num.
wa_packing_list-doc_type = c_xls.
wa_packing_list-obj_descr = text-022.
wa_packing_list-doc_size = wa_packing_list-body_num * c_length255.
APPEND wa_packing_list TO lt_packing_list.
CLEAR: wa_packing_list,l_cnt.
Email to be sent for multiple receivers
Add the recipients email address
LOOP AT s_receiv INTO wa_email.
l_email = wa_email-low.
wa_receivers-rec_type = c_rectyp.
wa_receivers-receiver = l_email.
wa_receivers-com_type = c_internet.
wa_receivers-notif_del = c_true.
wa_receivers-notif_ndel = c_true.
APPEND wa_receivers TO lt_receivers.
CLEAR : wa_receivers, wa_email, l_email.
ENDLOOP.
IF lt_receivers[] IS NOT INITIAL AND
i_itemrecord[] IS NOT INITIAL.
email sender
l_sender_address = sy-uname. " Stores the sender's address
*Function module to handel mail sending.
CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
EXPORTING
document_data = wa_doc_data
put_in_outbox = c_true
sender_address = l_sender_address
sender_address_type = c_sender_address_type
commit_work = c_true
IMPORTING
SENT_TO_ALL =
TABLES
packing_list = lt_packing_list
contents_bin = lt_attachment
contents_hex = lt_attachment1
contents_txt = lt_message
receivers = lt_receivers
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8 -
Excel attachment in external email sending
Hi guys.
Just having a bit problem in my excel attachment in external email sending (internet). The contents of my attachment are being considered as one column per line item, which is supposedly divided into columns according to its tab or space.
example: i sent this :
PO# Poitem
A 1
it will be displayed in excel as:
column1
PO# Poitem
A 1
it should be like this:
column1
column2
PO#
Poitem
A
1
can anyone tell me what additional fm(s) do I need to implement before calling fm: SO_NEW_DOCUMENT_ATT_SEND_API1 to send the email.
thanks a lot!
cheers,jagan,
Comapare your code with this program.
I need a create a excel file (or tab delimited file) and send it as attachment by mail to the user (in background processing). I use SO_NEW_DOCUMENT_ATT_SEND_API1. I have a problem, that 1 Excel line is splited into 2 lines in mail, because there is more then 255 chars in Excel line.
Can anybody help me?
report y_cr17_mail .
data method1 like sy-ucomm.
data g_user like soudnamei1.
data g_user_data like soudatai1.
data g_owner like soud-usrnam.
data g_receipients like soos1 occurs 0 with header line.
data g_document like sood4 .
data g_header like sood2.
data g_folmam like sofm2.
data g_objcnt like soli occurs 0 with header line.
data g_objhead like soli occurs 0 with header line.
data g_objpara like selc occurs 0 with header line.
data g_objparb like soop1 occurs 0 with header line.
data g_attachments like sood5 occurs 0 with header line.
data g_references like soxrl occurs 0 with header line.
data g_authority like sofa-usracc.
data g_ref_document like sood4.
data g_new_parent like soodk.
data: begin of g_files occurs 10 ,
text(4096) type c,
end of g_files.
data : fold_number(12) type c,
fold_yr(2) type c,
fold_type(3) type c.
parameters ws_file(4096) type c default 'c:\debugger.txt'.
Can me any file fromyour pc ....either xls or word or ppt etc ...
g_user-sapname = sy-uname.
call function 'SO_USER_READ_API1'
exporting
user = g_user
PREPARE_FOR_FOLDER_ACCESS = ' '
importing
user_data = g_user_data
EXCEPTIONS
USER_NOT_EXIST = 1
PARAMETER_ERROR = 2
X_ERROR = 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.
fold_type = g_user_data-outboxfol+0(3).
fold_yr = g_user_data-outboxfol+3(2).
fold_number = g_user_data-outboxfol+5(12).
clear g_files.
refresh : g_objcnt,
g_objhead,
g_objpara,
g_objparb,
g_receipients,
g_attachments,
g_references,
g_files.
method1 = 'SAVE'.
g_document-foltp = fold_type.
g_document-folyr = fold_yr.
g_document-folno = fold_number.
g_document-objtp = g_user_data-object_typ.
*g_document-OBJYR = '27'.
*g_document-OBJNO = '000000002365'.
*g_document-OBJNAM = 'MESSAGE'.
g_document-objdes = 'Manohar testing by program'.
g_document-folrg = 'O'.
*g_document-okcode = 'CHNG'.
g_document-objlen = '0'.
g_document-file_ext = 'TXT'.
g_header-objdes = 'Manohar testing by program'.
g_header-file_ext = 'TXT'.
call function 'SO_DOCUMENT_REPOSITORY_MANAGER'
exporting
method = method1
office_user = sy-uname
ref_document = g_ref_document
new_parent = g_new_parent
importing
authority = g_authority
tables
objcont = g_objcnt
objhead = g_objhead
objpara = g_objpara
objparb = g_objparb
recipients = g_receipients
attachments = g_attachments
references = g_references
files = g_files
changing
document = g_document
header_data = g_header
FOLMEM_DATA =
RECEIVE_DATA =
File from the pc to send...
method1 = 'ATTCREATEFROMPC'.
g_files-text = ws_file.
append g_files.
call function 'SO_DOCUMENT_REPOSITORY_MANAGER'
exporting
method = method1
office_user = g_owner
ref_document = g_ref_document
new_parent = g_new_parent
importing
authority = g_authority
tables
objcont = g_objcnt
objhead = g_objhead
objpara = g_objpara
objparb = g_objparb
recipients = g_receipients
attachments = g_attachments
references = g_references
files = g_files
changing
document = g_document
header_data = g_header
method1 = 'SEND'.
g_receipients-recnam = 'MK085'.
g_receipients-recesc = 'B'.
g_receipients-sndex = 'X'.
append g_receipients.
call function 'SO_DOCUMENT_REPOSITORY_MANAGER'
exporting
method = method1
office_user = g_owner
ref_document = g_ref_document
new_parent = g_new_parent
importing
authority = g_authority
tables
objcont = g_objcnt
objhead = g_objhead
objpara = g_objpara
objparb = g_objparb
recipients = g_receipients
attachments = g_attachments
references = g_references
files = g_files
changing
document = g_document
header_data = g_header. -
Send email with excel attachement
I'm using SO_DOCUMENT_SEND_API1 function to send a scheduled email with attachment.
But the problem is that the length of the string that I'm appending to the excel exceeds 256 characters.
So, the final excel file has trimmed values. Meaning only the first 255 characters are displayed.
I hope you guys understand what i'm saying.
So as I found out it seems that the above function can't be used in my case.
Do you know any other way of sending an email with attachment that meets my requirements.
Thanks,
Thilanka.Hi Buddy,
I also came across the same problem once. The only solution to this is tell your client to reduce the fields lenght which are not require.
Only 255 Char can be send on mail as per the fun Mod.
you have to reduce the length or display some data in the body of mail.
Hope this will solve your worry...
Thanks,
Krishna.. -
Email XLS excel attachment from ABAP
Hi,
I am trying to email an excel attachment from ABAP, but when I open in excel, it says not a recognizable format, but when I click OK it does open as a tab-delimited file and look OK.
Any ideas please?Hi,
Please check this link
http://www.sapdevelopment.co.uk/reporting/email/attach_xls.htm
aRs -
Email notification with excel attachment.
Hello,
I have a requirement to find an OSS note which talks about sending payment notification email with an excel attachment. If any body has come across this kind of note, please reply with the details.
Thank You.
Moderator message: please look for OSS notes yourself in the SAP Service Marketplace.
Edited by: Thomas Zloch on Jun 14, 2011 9:22 AMCan you post your code?
Regards,
Rich Heilman -
I attempted to eprint an email with an excel attachment. The attachment didn't print
I attempted to eprint an email with an Excel attachment. The email message printed but the Excel attachment does not print
Hi DaveF100,
You may want to refer to the help section of ePrintCenter.com here about attachments. In general though, Excel documents will have difficulty if they have complex variables in the document, such as pivot tables, macros, etc.
If I have solved your issue, please feel free to provide kudos and make sure you mark this thread as solution provided!
Although I work for HP, my posts and replies are my own opinion and not those of HP.
Maybe you are looking for
-
Acrobat Pro X, Vista Ultimate (32 bit). PDF printer is nowhere to be found. Tried reinstalling. I'm honestly not sure it was there when I installed it the first time. But it is there on my Win 7 machine. Thoughts? Fixes? Thanks. - Martin
-
Calculated member - Mode function
Hello, I need some help. I am quite new to MDX; I've created a cube and the measure needs to behave same as the MODE function in Excel (the following link describes what the function does). Apparently the only way of achieving this is by MDX (calling
-
Deleting the flashback recovery area and the files (Oracle 10g on Solaris 8
Hi, We have a dev. db which is small about 3 gb in all (crd files). for this I had enabled flashback and also put it in archivelog mode. then the db_recovery_file_dest_size grew to 3 gb. since space is an issue, I turned off the flashback feature. (b
-
Problems while displaying EXCEL sheets within OUTLOOK
Dear all, I have the following problem: a user within the company receives sometimes emails containing excel sheets. the user wants to use/work with the preview within outlook, unfortunately the displayed values are different compared with the value
-
Process to retiring signatures
Hello. Can I find reason for retiring signatures in signatures update ? I mean information like this: XXXX/0 - "IE buffer overflow" - retired due to time (vulnerability was published 5 years ago) XXXY/0 - "Firefox buffer overflow" - retired due to ma