Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

URL in E-mail notification

Former Member
0 Likes
905

Hi,

I am trying to develop a shopping cart approval workflow, in one of the step i am supposed to send the an e-mail notification to the approver, in the e-mail body i am supposed to place a URL clicking on which the user is navigated to his / her SAP inbox, this is SRM SAP inbox. can any body help me out on this.

Regards

Naren

6 REPLIES 6
Read only

Former Member
0 Likes
757

Hi,

what ever text you write in the email body with http://www or ftp://c:/ will behave as hyper link.

Please check the below link

<b>

Hope this helps.

Read only

Former Member
0 Likes
757

Hi,

U can use fm 'SO_NEW_DOCUMENT_SEND_API1' to send e-mail

then use document type as 'HTM' in exporting parameters

and move the link into a variblae say LINK

and use it as follows:-

See documentation of above mentioned FM used to send e-mail..

then use like this

wa_objcont = '<p align="right">Date:-'.

APPEND wa_objcont TO objcont.

CONCATENATE sy-datum6(2) '.' sy-datum4(2) '.' sy-datum+0(4)

INTO wa_objcont.

<b>APPEND wa_objcont TO objcont.

wa_objcont = '<A href="'.

APPEND wa_objcont TO objcont.

wa_objcont = LINK

APPEND wa_objcont TO objcont.

wa_objcont = '">Text to link</A>'.

APPEND wa_objcont TO objcont.</b>

hope this helps

reward if helpful.

Regards

-


Sachin Dhingra

Read only

0 Likes
757

Hi Sachin..

What will be the data type od thaat LINK variable?

Thanks

Read only

0 Likes
757

Hi Soni,

Sorry for Delay.

Data : LINK as string.

Regards

-


Sachin

Read only

Former Member
0 Likes
757

a similar case was handled,check this for url

call_browser

CALL FUNCTION 'CALL_BROWSER'

EXPORTING

URL = 'http://www.sap.com'.

or

call method cl_gui_frontend_services=>execute

exporting

document = 'https://www.sdn.sap.com'

exceptions

others = 1.

For mail check this code

FORM send_mail USING p_y16m_rcp_par STRUCTURE y16m_rcp_par.

  • Have a subject for the mail

g_s_document_data-obj_name = text-t02.

g_s_document_data-obj_descr = text-t03.

  • Fill receiver information

g_s_receivers-rec_type = p_y16m_rcp_par-rec_type.

g_s_receivers-rec_id = p_y16m_rcp_par-rec_id.

g_s_receivers-express = 'X'.

APPEND g_s_receivers TO g_t_receivers.

  • Call function to send mail

CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'

EXPORTING

document_data = g_s_document_data

document_type = 'RAW'

  • PUT_IN_OUTBOX = ' '

  • IMPORTING

  • SENT_TO_ALL =

  • NEW_OBJECT_ID =

TABLES

  • OBJECT_HEADER =

object_content = g_t_object_content

  • CONTENTS_HEX =

  • OBJECT_PARA =

  • OBJECT_PARB =

receivers = g_t_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

.

IF sy-subrc <> 0.

MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ENDIF.

ENDFORM. " SEND_MAIL

regards

Read only

Former Member
0 Likes
757

Hi,

Is there any function module using which, i give the user name and get the url link to his/her SRM SAP inbox

Regards

Narendiran Rathinavelu.