on 01-19-2011 4:22 PM
Hello Guys,
My requirement is to send Email to Approver once workitem is send to him in UWL after creation/change of contract. This is not offline approval but just an email specifying to check UWL.
In SRM 7.0 SAP has provided standard program /SAPSRM/OFFLINEAPPROVALSEND. This program sends email correctly to Approvers if correct date and time is mentioned on the screen.
But if I call this program in background through another program, it does not work. Program unables to find workitem in mentioned period since doesnot accept date and time parameters passed in the submit statement. It considers those blank and then internally assign system date and time to it.
Below is the sample code: ( we have also implemented BADI BBP_OFFLINE_APP_BADI to change text )
-
START-OF-SELECTION.
gv_time = sy-uzeit.
gv_datum = sy-datum.
to identify workitems which are generated in last 1 hour only
gv_time = gv_time - 3600.
SUBMIT /sapsrm/offlineapprovalsend WITH : p_jobsuf = '2',
p_bo_ty = 'BUS2000113',
x_n14all = c_x,
x_o_html = c_x,
x_o_dec = c_x,
x_wi_txt = c_x,
p_fromd = gv_datum,
p_fromt = gv_time,
x_alw_tr = c_x,
x_prio_2 = c_x .
-
Kindly help.
Regards,
Hema
It is not possible to call this program it resets date and time internally and does not work. I used dynamic Variant for the same.
Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For pure notification purposes, you can use Extended Notifications. This is a standard SAP solution. You don't need to modify your workflow or run any other jobs.
Check SAP help: [http://help.sap.com/saphelp_nw04s/helpdata/en/d5/581ee8d56f1247bf34cfcd66d16d81/frameset.htm]
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Any reason you called this program through another program? why can't you schedule this standard program directly rather than calling through another program.
Saravanan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
Reason is I need to change Value of the parameter Date and time on the screen. Contract( workitem) created in last 1 hour need to be executed only.
Date and time on screen work in a way that.. After that particular date and time whatever items are created mail is being send for all those items. Hence I can not keep those constant and should vary at each execution.
Regards,
Hema
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.