Bold lines in Mail Body
Hi experts,
I am reading the standard text using read_text (FM) and sending a mail .
For this I have used SO_NEW_DOCUMENT_ATT_SEND_API1.
Out of 50 lines I need some line to be BOLD.
Can anyone help me in solving this issue?
Thanks in Advance,
Harsha.
HI,
One way I can think of is.... create a Report Spool with characters bold whereever applicaple...
and then read the spool job and send mail....'
this is slightly lengthy...way
Regards,
Nikhil
Similar Messages
-
E-Mail body content appears in single line as a string.
Could someone advise the way to format(space, new line, bold etc) E-Mail body content in BPEL.
I wanted an email body content be sent as following:
Hi,
This is my test email through BPEL.
Well Done!
Cheers
R
But when it actually sent, it just appeared as continuous string as follows:
Hi, This is my test email through BPEL. Well Done! Cheers R
Thanks
TI tried a workaround and used html tags in the email body in BPEL, as follows:
<%string('<html>
<body>
Hi, <used line break wherever required ie. br>
This is my test email through BPEL.<br>
Well Done!<br><br>
Cheers<br>
R
</body>
</html>')%>
It worked fine as expected. Still, with plain text, it appears as single straight line. I welcome comments on this!
cheers
thobula -
Apply color in send mail body part
Hi SAP Gurs,
I am creating program for sending mail to user.. in that mail i so many header and line item are there, i want to apply color or bold, italic format in body part.... so its look like seprate in body part
So is there any possibilty to apply color or bold words in mail body part?
Please help me......
Thanks zeniYou can use the HTML text in the Message body part to get the Colors, Bold, Italics like effect in the mail.
Please refer my answer in this post.
formating possible in sending mail program
Regards,
Naimesh Patel -
Hi,
I built the text(Body) of the mail with 19 lines. But while triggering through workflow the last 3 lines of the body displayed in the same line instead of different line. I used SO_NEW_DOCUMENT_SEND_API1 function module for mail sending activity,
Can anybody experienced this kind of problems earlier? If so please kindly help me to sort out this asap. Useful responses will be rewarded.
Thanks in advance.Hi
I have used this function module to send mail.
SO_NEW_DOCUMENT_SEND_API1
I have not problem and not found any duplicate entries.
Please send your piece of code where you are adding text line.
It may happened because of not clearing the memory values.
Rgds,
Sriram -
My email only display the list of mails in my in box with a preview of the first two lines of the body of the message. When one clicks on the message to open it, only the header is displayed in the right hand side of the screen - the actual message is missing. This happens on older mail previously downloaded that use to work properly as well. Any idea how to fix this?
Try closing the Mail app completely and see if it works properly when you re-open the app : from the home screen (i.e. not with the Mail app 'open' on-screen) double-click the home button to bring up the taskbar, then press and hold any of the apps on the taskbar for a couple of seconds or so until they start shaking, then press the '-' in the top left of the Mail app to close it, and touch any part of the screen above the taskbar so as to stop the shaking and close the taskbar.
If that doesn't work also do a reset : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the red slider), after which the Apple logo should appear - you won't lose any content, it's the iPad equivalent of a reboot. -
On my iPad, E-mails have subject line but no body?
E-mails on my iPad only show sender and subject line, but no body?
Try closing the Mail app completely and see if it works properly when you re-open the app : from the home screen (i.e. not with the Mail app 'open' on-screen) double-click the home button to bring up the taskbar, then press and hold any of the apps on the taskbar for a couple of seconds or so until they start shaking, then press the '-' in the top left of the Mail app to close it, and touch any part of the screen above the taskbar so as to stop the shaking and close the taskbar.
If that doesn't work also do a reset : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the red slider), after which the Apple logo should appear - you won't lose any content, it's the iPad equivalent of a reboot. -
Bold, Colors in mail - Urgent
Hi all,
I am using a function mod for mail alert. The user wants cretain names as BOLD & Colors in the text.
Is there any function mod which sends the mail with BOLD, COLORS & any other options?
Pls urgent.
Thanks in advance.
VijayVijay,
Interesting , It will work with my below code. If you don'nt want an attachment then just remove it from this program..
Believe this will solve your problem.
Cheers,
Thomas.
REPORT test.
DATA: att_size TYPE i, " att Size
att_itab_size TYPE i, " Attachment size
mailtxt_size TYPE i. " Text in mail size
DATA:
it_mailpack LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE, " Dist details
it_mailhead LIKE solisti1 OCCURS 1 WITH HEADER LINE," Header data
it_reclist LIKE somlreci1 OCCURS 0 WITH HEADER LINE, " Rec List
it_mailtxt LIKE solisti1 OCCURS 0 WITH HEADER LINE, " Mail Text
it_att_data LIKE solisti1 OCCURS 0 WITH HEADER LINE, " Attachment data
it_doc_att LIKE sodocchgi1. " Attri of new doc
* Text in the mail.
it_mailtxt-line =
'<BODY BGCOLOR="#FFFFCC">' &
'<B> This is a test mail, Line Number--1</B><BR>'
APPEND it_mailtxt.
it_mailtxt-line = '<I> This is a test mail, Line Number--2' &
' This is a test mail, Line Number--2</I><BR>'.
APPEND it_mailtxt.
it_mailtxt-line = '<U> This is a test mail, Line Number--3' &
' This is a test mail, Line Number--3' &
' This is a test mail, Line Number--3</U>'.
APPEND it_mailtxt.
DESCRIBE TABLE it_mailtxt LINES mailtxt_size.
* Create the att File
concatenate '<BODY><B>Attachment Line Number 1</B><BR>' space into
it_att_data-line.
APPEND it_att_data.
concatenate '<I>Attachment Line Number 2</I><BR>' space into
it_att_data-line.
APPEND it_att_data.
concatenate '<U>Attachment Line Number 3</U>' space into
it_att_data-line.
APPEND it_att_data.
DESCRIBE TABLE it_att_data LINES att_itab_size.
* Attributes of new doc
CONCATENATE 'Attach' space 'mail'
INTO it_doc_att-obj_descr SEPARATED BY space.
it_doc_att-sensitivty = 'F'.
it_doc_att-doc_size = mailtxt_size * 255.
* Create Pack to text in mail body.
it_mailpack-transf_bin = space.
it_mailpack-head_start = 1.
it_mailpack-head_num = 0.
it_mailpack-body_start = 1.
it_mailpack-body_num = mailtxt_size.
it_mailpack-doc_type = 'HTM'.
APPEND it_mailpack.
* Create Pack for Attach.
it_mailpack-transf_bin = 'X'.
it_mailpack-head_start = 1.
it_mailpack-head_num = 1.
it_mailpack-body_start = 1.
it_mailpack-body_num = att_itab_size.
it_mailpack-doc_type = 'HTM'.
CONCATENATE 'My' space 'Attachment' INTO it_mailpack-obj_descr.
it_mailpack-doc_size = att_itab_size * 255.
APPEND it_mailpack.
it_reclist-receiver = '[email protected]'.
it_reclist-express = 'X'.
it_reclist-rec_type = 'U'.
*it_reclist-notif_del = 'X'. " request delivery notification
APPEND it_reclist.
* Call FM to send email
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = it_doc_att
put_in_outbox = 'X'
TABLES
packing_list = it_mailpack
object_header = it_mailhead
contents_txt = it_mailtxt
contents_bin = it_att_data
receivers = it_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.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF. -
I need to put hyperlink in th mail body.I am using the following lines to display the hyperlink........................
<a href = xyz.com > test </a>
But the problem is that instead of displaying the test hyrerlink it is showing me :-
<a href = _xyz.com_ > test </a>.
How to fix this problem.Here it is
<a href="www.xyz.com"> test </a>
that's it.
Regards,
IA
Edited by: Imthiaz Ahmed on Apr 9, 2008 4:55 PM -
How to send mail body using RE_CN_RA_INVOICE interface from RECPA520
Hi ABAP Guru,
I am using a standard interface RE_CN_RA_INVOICE for tcode RECPA520 for generating pdf form and send the corresponding PDF to corresponding address maintained in Business Partner.The problem is mail is sending with attachment but there is no mail body.
Please helpYou have to convert your long string to a table of shorter strings.
There may be other ways, but one possibility is to use a loop to process you string.
while (there is something left)
put the next e.g. 1024 characters in a new row of your table
endwhile
If you need to reconstruct your string from the table, don't use simple concatenation since it will remove blanks at the end of lines. Believe me (from experience) sooner or later this will happen.
Instead you need to either set the subsections of your long string, or insert from the end of your table and keep shifting the contents (probably less efficient) right -
Hw to write text in mail body in UTL SMTP in oracle
hi all
i m using oracle demo mail package to send csv file as attachment to different users its successfull and i can also able to attach text file to it
but i m unable to write any text in mail body .
e.g.
mail body can be--
hi
This is test mail.
Regds
Sender.
can anyone suggest some way?u can try this code
this code takes the file from database and attach with mail and also send the body with it
it works fine.
CREATE OR REPLACE
procedure pdf_mail(
p_sender varchar2, -- sender, example: 'Me '
p_recipients varchar2, -- recipients, example: 'Someone '
p_subject varchar2, -- subject
p_text long, -- text
p_case_id number,
p_email_log_id number
-- p_filename varchar2, -- name of pdf file
p_blob blob pdf file
) is
conn utl_smtp.connection;
i number;
len number;
p_message_part varchar2(32767);
cursor c1 is
select file_name,document_pic
from clm_case_attachments ca,email_log_detail em
where
case_id = p_case_id
and ca.CASE_ATTACHMENT_ID = em.ATTACHMENT_ID
and em.ACTIVE = 'Y'
and em.EMAIL_LOG_ID = p_email_log_id;
BEGIN
conn := demo_mail.begin_mail(
sender => p_sender,
recipients => p_recipients,
subject => p_subject,
mime_type => demo_mail.MULTIPART_MIME_TYPE);
demo_mail.attach_text(
conn => conn,
data => p_text,
mime_type => 'text/html');
for lp in c1 loop
demo_mail.begin_attachment(
conn => conn,
mime_type => 'application/pdf',
inline => TRUE,
filename => lp.file_name,
transfer_enc => 'base64');
-- split the Base64 encoded attachment into multiple lines
i := 1;
len := DBMS_LOB.getLength(lp.document_pic);
WHILE (i < len) LOOP
IF(i + demo_mail.MAX_BASE64_LINE_WIDTH < len)THEN
UTL_SMTP.Write_Raw_Data (conn
, UTL_ENCODE.Base64_Encode(
DBMS_LOB.Substr(lp.document_pic, demo_mail.MAX_BASE64_LINE_WIDTH, i)));
ELSE
UTL_SMTP.Write_Raw_Data (conn
, UTL_ENCODE.Base64_Encode(
DBMS_LOB.Substr(lp.document_pic, (len - i)+1, i)));
END IF;
UTL_SMTP.Write_Data(conn, UTL_TCP.CRLF);
i := i + demo_mail.MAX_BASE64_LINE_WIDTH;
END LOOP;
demo_mail.end_attachment(conn => conn);
end loop;
demo_mail.end_mail( conn => conn );
END;
/ -
Hw to write txt in mail body using UTL mail when sending mail with attachme
hi all
i m using oracle demo mail package to send csv file as attachment to different users its successfull and i can also able to attach text file to it
but i m unable to write any text in mail body .
e.g.
mail body can be--
hi
This is test mail.
Regds
Sender.
can anyone suggest some way?u can try this code
this code takes the file from database and attach with mail and also send the body with it
it works fine.
CREATE OR REPLACE
procedure pdf_mail(
p_sender varchar2, -- sender, example: 'Me '
p_recipients varchar2, -- recipients, example: 'Someone '
p_subject varchar2, -- subject
p_text long, -- text
p_case_id number,
p_email_log_id number
-- p_filename varchar2, -- name of pdf file
p_blob blob pdf file
) is
conn utl_smtp.connection;
i number;
len number;
p_message_part varchar2(32767);
cursor c1 is
select file_name,document_pic
from clm_case_attachments ca,email_log_detail em
where
case_id = p_case_id
and ca.CASE_ATTACHMENT_ID = em.ATTACHMENT_ID
and em.ACTIVE = 'Y'
and em.EMAIL_LOG_ID = p_email_log_id;
BEGIN
conn := demo_mail.begin_mail(
sender => p_sender,
recipients => p_recipients,
subject => p_subject,
mime_type => demo_mail.MULTIPART_MIME_TYPE);
demo_mail.attach_text(
conn => conn,
data => p_text,
mime_type => 'text/html');
for lp in c1 loop
demo_mail.begin_attachment(
conn => conn,
mime_type => 'application/pdf',
inline => TRUE,
filename => lp.file_name,
transfer_enc => 'base64');
-- split the Base64 encoded attachment into multiple lines
i := 1;
len := DBMS_LOB.getLength(lp.document_pic);
WHILE (i < len) LOOP
IF(i + demo_mail.MAX_BASE64_LINE_WIDTH < len)THEN
UTL_SMTP.Write_Raw_Data (conn
, UTL_ENCODE.Base64_Encode(
DBMS_LOB.Substr(lp.document_pic, demo_mail.MAX_BASE64_LINE_WIDTH, i)));
ELSE
UTL_SMTP.Write_Raw_Data (conn
, UTL_ENCODE.Base64_Encode(
DBMS_LOB.Substr(lp.document_pic, (len - i)+1, i)));
END IF;
UTL_SMTP.Write_Data(conn, UTL_TCP.CRLF);
i := i + demo_mail.MAX_BASE64_LINE_WIDTH;
END LOOP;
demo_mail.end_attachment(conn => conn);
end loop;
demo_mail.end_mail( conn => conn );
END;
/ -
How to put mail body while sending Payment Advice Note by mail
Hi,
I am sending payment advice form through mail using the BTE 2040.
Everything is fine and mail is coming properly but mail does not have any body line. It just contains the PDF as an attachment.
I want to put mail body in that. I have just copied the Script, I have not copied the driver program.
E.g
Hello,
Please find the payment advice note as an attachment.
Kindly advice how to put mail body in that mail, is there any BTE through which we can put the mail body?
Kindly help.
Regards
Sachin YadavHi,
I am sending payment advice form through mail using the BTE 2040.
Everything is fine and mail is coming properly but mail does not have any body line. It just contains the PDF as an attachment.
I want to put mail body in that. I have just copied the Script, I have not copied the driver program.
E.g
Hello,
Please find the payment advice note as an attachment.
Kindly advice how to put mail body in that mail, is there any BTE through which we can put the mail body?
Kindly help.
Regards
Sachin Yadav -
Email Purchase Order with mail body
Hi, ALL,
I would like to email purchase order to vendors with customized email subject and body. I did configuration in IMG according to note 191470. I also set up title and text in IMG. Now I can email PO with subject (title). But there is no mail body ( the text? ) . Is there anybody know how to do it? Thanks a lot!
JackHi,
In standard you can send purchase order by mail with subject line (title) only and you can not send mail body text.
Check the link:
Send PO External email with attachement and Body text
Regards,
Biju K -
I need to send a mail through my ABAP Program. The content of the mail is Internal Table.
I need to format the content of the Internal Table with proper spacing and heading.
ex:how i am getting my data in mail body
empno empname city region
111 abcdef hyedarabad Ap
112 abcedfgh banglore KArnataka
113 abc mubmai maharastra
Somebody please help me in this regard.Hi,
this is the code
i dont want any attachment
*& Form process_mail
form process_mail .
data: offset type i,
llen(40) type c.
sort it_final by manager_pernr.
loop at it_final .
To get the employee name
read table it_pa0001 with key pernr = it_final-emp_pernr.
if sy-subrc = 0.
v_empname = it_pa0001-ename.
endif.
at new manager_pernr.
To get the manager name
read table it_pa0001 with key pernr = it_final-manager_pernr.
if sy-subrc = 0.
v_managername = it_pa0001-ename.
endif.
Fill mail-text
perform mail_text.
endat.
if it_final-wbs is not initial.
offset = 0.
describe field it_final-emp_pernr length llen in character mode.
write it_final-emp_pernr to it_mailtext+offset(llen).
offset = llen + offset.
describe field v_empname length llen in character mode.
write v_empname to it_mailtext+offset(llen).
offset = llen + offset.
describe field it_final-wbs length llen in character mode.
write it_final-wbs to it_mailtext+offset(llen).
offset = llen + offset.
describe field it_final-total_hrs length llen in character mode.
write it_final-total_hrs to it_mailtext+offset(llen).
offset = llen + offset.
it_mailtext-line = it_mailtext.
append it_mailtext.
clear it_mailtext.
elseif it_final-kostl is not initial.
offset = 0.
describe field it_final-emp_pernr length llen in character mode.
write it_final-emp_pernr to it_mailtext+offset(llen).
offset = llen + offset.
describe field v_empname length llen in character mode.
write v_empname to it_mailtext+offset(llen).
offset = llen + offset.
describe field it_final-kostl length llen in character mode.
write it_final-kostl to it_mailtext+offset(llen).
offset = llen + offset.
describe field it_final-total_hrs length llen in character mode.
write it_final-total_hrs to it_mailtext+offset(llen).
offset = llen + offset.
it_mailtext-line = it_mailtext.
append it_mailtext.
clear it_mailtext.
endif.
at end of manager_pernr.
clear it_mailtext.
append it_mailtext.
append it_mailtext.
it_mailtext-line = 'Regards,'.
append it_mailtext.
clear it_mailtext.
it_mailtext-line = 'Team'.
append it_mailtext.
clear it_mailtext.
append lines of it_mailtext to it_objtext.
append it_mailtext.
clear it_mailtext.
append it_mailtext.
concatenate 'This is an auto notification.'
'Please do not reply to this mail ID'
into it_mailtext-line separated by space.
append it_mailtext.
clear it_mailtext.
append it_mailtext.
Creation of the entry for the compressed document
clear it_objpack-transf_bin.
it_objpack-transf_bin = ' '.
it_objpack-head_start = 1.
it_objpack-head_num = 0.
it_objpack-body_start = 1.
it_objpack-body_num = tab_lines.
it_objpack-doc_type = 'RAW'.
append it_objpack.
perform send_mail.
endat.
endloop.
endform. " process_mail
*& Form mail_text
form mail_text .
data :head_desc like it_mailtext,
body_desc like it_mailtext.
clear it_mailtext.
refresh it_mailtext.
concatenate 'Dear' v_managername
into it_mailtext-line separated by space.
concatenate it_mailtext-line ','
into it_mailtext-line.
append it_mailtext.
clear it_mailtext.
append it_mailtext.
concatenate 'The following unapproved timesheets'
'exist in your ESS.'
into it_mailtext-line separated by space.
append it_mailtext.
clear it_mailtext.
concatenate 'Please ignore this mail if already'
'approved.'
into it_mailtext-line separated by space.
append it_mailtext.
clear it_mailtext.
append it_mailtext.
it_mailtext-line+2(8) = 'Emp-No'.
it_mailtext-line+15(8) = 'Emp-Name'.
it_mailtext-line+65(20) = 'WBS/CostCenter'.
it_mailtext-line+84(10) = 'Total Hrs'.
append it_mailtext.
clear it_mailtext.
concatenate '----
into it_mailtext-line .
append it_mailtext.
clear it_mailtext.
append it_mailtext.
endform. " mail_text
*& Form send_mail
form send_mail .
clear v_error.
clear fs_object_hd_change.
clear v_approver_mailid.
fs_object_hd_change-objla = sy-langu.
fs_object_hd_change-objnam = 'MAIL'.
fs_object_hd_change-objdes = 'Unapproved Timesheets'.
fs_object_hd_change-objpri = 3.
fs_object_hd_change-objsns = 'F'.
fs_object_hd_change-ownnam = v_usrid.
refresh it_receivers_text.
clear it_receivers_text.
move sy-datum to it_receivers_text-rcdat .
move sy-uzeit to it_receivers_text-rctim.
move '1' to it_receivers_text-sndpri.
move 'X' to it_receivers_text-sndex.
move 'U-' to it_receivers_text-recnam.
move 'U' to it_receivers_text-recesc.
move 'INT' to it_receivers_text-sndart.
move '5' to it_receivers_text-sortclass.
append it_receivers_text.
v_approver = it_final-manager_pernr.
if v_approver_mailid is initial.
call function 'ZBAPI_GET_MAIL_ID_FROM_PERNR'
exporting
pernr = v_approver
importing
mail_id = v_approver_mailid.
if v_approver_mailid is initial.
v_error = 'X'.
v_message = 'Failed to obtain approver''s mailid'.
endif.
endif.
it_receivers_text-recextnam = v_approver_mailid.
append it_receivers_text.
if v_sim_mode = '0'. " Not in simulation mode
v_owner = v_usrid.
else.
v_owner = sy-uname.
endif.
call function 'SO_OBJECT_SEND'
exporting
object_hd_change = fs_object_hd_change
object_type = 'RAW'
outbox_flag = 'X'
owner = v_owner
tables
objcont = it_mailtext
receivers = it_receivers_text
exceptions
active_user_not_exist = 1
communication_failure = 2
component_not_available = 3
folder_not_exist = 4
folder_no_authorization = 5
forwarder_not_exist = 6
note_not_exist = 7
object_not_exist = 8
object_not_sent = 9
object_no_authorization = 10
object_type_not_exist = 11
operation_no_authorization = 12
owner_not_exist = 13
parameter_error = 14
substitute_not_active = 15
substitute_not_defined = 16
system_failure = 17
too_much_receivers = 18
user_not_exist = 19
originator_not_exist = 20
x_error = 21
others = 22.
v_char_subrc = sy-subrc.
if sy-subrc ne 0.
v_error = 'X'.
concatenate 'Error:'
v_char_subrc
'Could not send email to ' v_mailid
into v_message
separated by space.
else.
commit work.
v_message = 'Approval mails sent'.
endif. -
Hi to all
Is it possible to format the mail body that we create using FM 'SO_NEW_DOCUMENT_ATT_SEND_API1' like a rich user interface?
Kindly suggest.
Thanks & Regards
VipinIts possible to give html tags in the body internal table thereby make it a rich user interface. For html you may need to use document type as HTM.
I 've given an example in this link. Please have a look.
Re: Bold, Colors in mail - Urgent
Rgds,
TM.
Maybe you are looking for
-
I couldn't find "view in finder" option in iPhoto 11.
When i was using iPhoto 10 I could find an option of "view in finder" if I right-click on a picture. But now I bought iPhoto 11 and installed it in my MacBook Pro. But, I couldn't find "view in finder" option in iPhoto 11. Could you please help me wi
-
Need hel attendant console- missing leading zero
I have a customer wher we did an upgrade from 4.1(3) to CUCM 7.1(2), we installed the AC plugin from the CUCM, and the AC is working but now the cutomer complains that they can't dial back from the AC because they are missing the leading zeros from t
-
How can I redirect a web application's output from my local machine that is running the Java System Application Server (v. 9.1, bundled in Java EE 5 SDK) to a remote web server? The application server listens on localhost, port 2278 and displays page
-
Hello guys , I have a parameters no modifiable ,but I want to change it to modifiable, I change the name of the parameter already and it works , but i want to know why my parameter p_file have the propierty of no modifiable. ?
-
Two days ago, I loaded Light Room 6. Today I went back to Light Room 5. LR 6 corrupted an entire folder of images, and caused errors on my Raid 5 causing win 7 to run "Chk Dsk" and fix the errors to the operating system. LR 5 has not shut down for th