Reg : mail step in wf
hi ,
In my workflow..when ever quotation is created.(suppose USER1 has created quotation)......
Workflow starts and there is an activity with task and rule in task.
The rule finds the responible agent and sends the work item to that ID (suppose USER2 has received the workitem).
After the agent checks the workitem in his inbox..and approves the quotation..... a mail should be sent to the user who careted quataion(USER1).
I kept a mail step below thw activity with agent as workflow intitaor.
but its not working.
what would be the mistake??
Can anyone help me ????
regards
Arjun
Hi Arjun,
Check if you are able to get the value of the WF initiator in the workflow container.
This would only come if you have binded the triggering event container to the workflow container.
This is done in 'Basic Data' button, 'Start Events' tab. Here do the binding in between the event and the workflow as &_EVT_CREATOR& => &_WF_INITIATOR&.
Hope this helps!
Regards,
Saumya
Similar Messages
-
hi,
I have a user decision with approve reject outcomes.
and this user decision step is sent to 3 different users (USERID1, USERID2, USERID3) with help of RULE.
when user 1 clicks approve .......a mail is sent him(to his userid USERID1) saying that he clciked approve outcome.
similarly
when user 2 approves .......a mail is sent to his userid only(to his userid USERID2) ,
when user 3 approves .......a mail is sent to his userid only (to his userid USERID3) .
how to acheive this?????
i kept a mail step after user decision step????
bue i need to asssign the receiver ..so i selected the EXPRESSION and select the container variable &AGENT&.
But this is not working .
Can anyone help me??
Regards
arjun .hi siva,
That was really gr8 answer from u.
ur magic really worked out in a sec .
thx very much .
regards
Arjun -
SEND Mail Step Mail body is not getting displayed in SOST Transaction
Hi Gurus,
I have a very strange problem. I have developed a workflow to send notifications. My client wants to send notifications in different languages based on the user. If the users language is english, the notification mail should trigger in english. If the user's language is French, then the notification mail should trigger in French. like if the user's language is chinese, the notification should be in chinese.
I have used the Standard text objects (SO10) and read the text based on language of the user into the workflow container element. We have passed that container element (which has the required text in users language) to text_lines in SEND MAIL step of the workflow. I am getting the text in the correct language based on the user.
When the mail triggers to user, the user is getting a blank email. There is no body/text in that email. We have checked the SOST transaction and observed that the notification email doesnt have any body, even though we have the text in workflow log. For the users who have the English language, they are getting the text in their mail, SOST and workflow log. Where as for the other languages (French, Chinese, Spanish etc...), they are getting the blank mail, (SOST doesnu2019t have body text) but in workflow log the correct text(based on user language) is getting displayed.
I tested the same workflow in devlopment & quality, everything is working fine. All users (English & Non-English) getting mails in their respective languages. Where as in production, only for English users it is working, but for Non-English users it is not working. I have compared all three environments workflow definitions and they are same. I do not understand why this is behaving differently in production. Could you please help me how do I resolve this issue.
May I know, does any one has faced similar issue. I request you to throw some light in this area.
Thanks in advance.
Regards,
V.NagarajuHello,
Interesting! That seems like a foolproof way to handle the language problem
which can be a challenge in multi-language workflows. Please be sure to tell us
how you solve this and what the cause was.
You keep referring to the language of the "user". I assume you mean the
mail recipient?
You have to watch out with the workflow logs, they take the language settings
of the person viewing it into account when displaying texts, unlike SOST.
"I have used the Standard text objects (SO10) and read the text based on language of the user into the workflow container element"
Which user actually executes the method to do this? Is it WF-BATCH?
Are you using an actual SendMail step? And you reference the variable text_lines##
in the task description?
regards
Rick Bakker
hanabi technology -
Mail step should be sent to all the users in multiple condition
hi experts,
I have a requirement on invoice posting.Say if invoice amount is 1000 then person A can post the invoice.
if >= 1000 person B can post the invoice.
If >=2000 person C can post the invoice.
what i have did is, created a multiple condition and then based on the inv amount assigned 3 methods for invoice posting.My problem is if a person posts an invoice amount of 1000.A mail has to be sent to Person B and C informing that an amount of 1000 is posted with user id.Same for person B, ie mail should be sent to person A and C informing regarding invoice posting.Now inside the multiple condition i cannot assign mail step.Coz based on the condition it will go to a particular user for invoice posting but where as mail should be sent to all the users.So how can i achieve this??.Hi Priyanka,
I am getting 1 thing why you need need multiple conditions. No need to create any multiple conditions.
1. Create a rule using transaction PFAC. (you can use the example as Rule: 0000168).
a. Create an function module with table parameters as ACTOR_TAB (type SWHACTOR) and AC_CONTAINER (Type
SWCONT). You can aswell copy the FM used in 168 rule and change it. check the logic mentioned below.
b. In PFAC transaction, go to container tab and create 2 container elements. For amount and Mail_indicator (type should be
same as that of the amount field in your workflow) .
2. Use this Rule in your workflow to send mail.
Logic:
""Lokale Schnittstelle:
*" TABLES
*" ACTOR_TAB STRUCTURE SWHACTOR
*" AC_CONTAINER STRUCTURE SWCONT
*" EXCEPTIONS
*" NOBODY_FOUND
INCLUDE <CNTAIN>.
DATA BEGIN OF ORG_OBJECT OCCURS 0.
INCLUDE STRUCTURE SWHACTOR.
DATA END OF ORG_OBJECT.
DATA: BEGIN OF NEW_AC_CONTAINER OCCURS 3.
INCLUDE STRUCTURE SWCONT.
DATA: END OF NEW_AC_CONTAINER.
DATA: V_AMOUNT TYPE <AMOUNT FIELD>.
DATA: V_MAIL_INDICATOR TYPE <FLAG>.
REFRESH: actor_tab.
Get the org-object under consideration. AMOUNT is the container name defined in your PFTC transaction
SWC_GET_ELEMENT AC_CONTAINER 'AMOUNT' 'V_AMOUNT'.
Get the org-object-type and the org-object id.
SWC_GET_ELEMENT AC_CONTAINER 'MAIL_INDICATOR' V_MAIL_INDICATOR .
Pass the org-object, the org-object-type and the org-object-id
to a new container.
The org object get a new name: ORG_AGENT.
SWC_SET_ELEMENT NEW_AC_CONTAINER 'AMOUNT' 'V_AMOUNT'.
SWC_SET_ELEMENT NEW_AC_CONTAINER 'MAIL_INDICATOR' V_MAIL_INDICATOR .
check for V_AMOUNT and V_MAIL_INDICATOR.
if the v_amount = 1000 .'
if v_mail_indicator = ' '.
actor_tab-OTYPE = 'US' .
actor_tab-OBJID = 'SAPUSER1'.
append actor_tab
else.
actor_tab-OTYPE = 'US' .
actor_tab-OBJID = 'SAPUSER2'.
append actor_tab
actor_tab-OTYPE = 'US' .
actor_tab-OBJID = 'SAPUSER3'.
append actor_tab
endif.
endif.
Similarly write the logic for other conditions.
This way you can use same for different purposes.
If you pass the indicator that means you are sending mail to other approvers for information.
Revert back if u need more help.
Regards,
Gautham -
How to send mails in HTML format from the send mail step of workflow?
Hi,
I have a requirement where I need to send mails in the html format from the send mail step of the workflows.
But what I found out that the html tags are not renderd and as such the output is in plain text.
I know that there is an alternative of using an activity step and use my own custom code from within there,But due to certain business constraints, I need to use the send mail step only.
My SCOT settings are all right.
Please let me know how it can be done.
Thanks,
Samrat.Samrat,
It can't be done, you have to use your own activity step.
What are these constraints that refrain you from doing that?
Rgds,
Patrick -
Regarding runtime error ehile execution of Mail step in workflow
Hi all when i execute mail step in workflow i am getting following error-
SQL error in the database when accesing a table.
How to correct the error
Database error text........: "SQL system error. MSGID= Job=038082/DEV05/WP02"
Internal call code.........: "[RSQL/INSR/ARFCSDATA ]"
Please check the entries in the system log (Transaction SM21).
If the error occures in a non-modified SAP program, you may be able to
find an interim solution in an SAP Note.
If you have access to SAP Notes, carry out a search with the following
keywords:
"DBIF_RSQL_SQL_ERROR" "CX_SY_OPEN_SQL_DB"
"SAPLARFC" or "LARFCU03"
"END_TRANSACTION_NONE_LOCAL_UPD"
If you cannot solve the problem yourself and want to send an error
notification to SAP, include the following information:
1. The description of the current problem (short dump)
To save the description, choose "System->List->Save->Local File
(Unconverted)".
2. Corresponding system log
Display the system log by calling transaction SM21.
Restrict the time interval to 10 minutes before and five minutes
after the short dump. Then choose "System->List->Save->Local File
(Unconverted)".
3. If the problem occurs in a problem of your own or a modified SAP
program: The source code of the program
In the editor, choose "Utilities->More
Please guide.
Thanks.Hi Sanjay,
Firstly are you using Send mail Activity or are u calling Fm SO_DOCUMENT_SEND_API1.
Well I suppose u are calling the FM, in that case just check the data that you are fetching before calling this FM. This error is related to sql query so check your select statements used before sending mail.
Hope this helps. -
How to send Formatted text in send mail step
Greetings
I need to send a formatted email in the send mail step of WF, however I don't se any option to change the font/size/color etc. Currently the email body contains only simple text.
Appreciate your quick response.
Thanks>
Weise, Roman wrote:
> Hello Manas,
>
> sending a formated email with a standard mail step will not be posible as far as i know. in general sending formated emails only makes sense if you can be sure that you are in a completely consolidated environment, e.g. a company where everyone uses the same mail client with a configuration ensure through a company pc template. if you try to send formated mails to heterogeneous environment you won't be happy as email clients / web mail providers are so different that you will be busy triying to get an acceptable layout for eternity (i deal a lot with mail sending to externals and always have these discusions with my customers).
>
> If you are sure you have a consolidated environment you could try to send a smartform through a functional method in a workflow. smartforms allow a high flexibility in layout. If you want to try this option i can give you additional help on the implementation.
>
> Best Regards
>
> Roman Weise
Hi Roman,
I have the same issue and I'm in a consolidated environment. I'd like to know if sending through a smartform will produce an e-mail message with attachment or just a text mail and the steps required to do so.
thanks in advance
Stefano -
Variable char 255 in the body of a Send Mail step
When I include a variable (char 255) of the workflow container in a "Send Mail" step body, in the sent mail I can't see all the characters. It seems to cut about 80 characters.
Can anybody help me.
Thanks in advance.
SoniaYes ..There is a limitation on length, It can be extended upto 130 character, there is some note avaliable for that (please check) , but for more than 130 character i am not sure it is possible ..i solved it by splitting
-
Mail step not working with expression
Hi Experts,
I am using the business object bus2080 for Tcode iw21, to trigger workflow on notification status change. I have mail step in my workflow,mail is being sent successfully when it has only text, but when i am using the expressions, say notification number in that mail, no mail is being send, getting error "Error handling for work item 000000660111".
Please let me know your valuable comments on this issue.
Thanks
IshtiyaqHi Rob,
The worflow container I am using is of the type BUS2080. Binding in the start event is as below
Event -> Workflow
&_EVT_OBJECT& &ZBUS2080&
and in the Mail Step
Workflow-> Mail Step
&ZBUS2080& &ZBUS2080&
Also in the mail subject and body I am adding the expression using button 'Insert Expressions'.
thanks,
Ishtiyaq -
Error in SEND MAIL step with exception 1001
Hi Experts,
I am getting exception 1001, error message Document <&> could not be sent
when I put my user id in SEND MAIL step. In the same workflow,I put my user id at an activity step,and I am sucessfully receiving work item generated at that activity step in SAP Business workplace inbox.
Can anyone please tell me why exception is happening in SEND MAIL step.
Thanks,
Sonali.Hi Surjith,
Firstly Workflow was running fine till yesterday.
Secondly, I put expression &_WF_INITIATOR& in the Send Mail step. Notification should go to my SAP business workplace->inbox->Document. But it is not going. Exception 1001 is happening.
But in the same workflow, just at the immediate next activity step I put &_WF_INITIATOR& again as agent. And I am successfully receiving workitem in SAP business workplace->inbox->workflow for this activity step.
Please guide me how to resolve the issue and why suddenly it is happening so.
Thanks,
Sonali. -
In workflow i have user decision step with attachment as PDF, after he rejects i should send a notification to the initiater about rejection, I used send mail step after the user decision step of rejection branch,, the send mail step is giving following error..occurs
Executing batch work item ;Work item 000000653444: Object SELFITEM method SENDTASKDESCRIPTION cannot be executed.
EXECUTE_METHOD_OBJECT_SYNC ; Method container for work item cannot be created
EXECUTE_METHOD_BOR ; method container for work item cannot be created
Executing batch work item Unable to instantiate object '_ATTACH_OBJECTS'
is this attachment is creating any problem..Hi Sunil,
In the user decision step check the binding. The attachment should be binded from workflow container to the task container and from the task container to the workflow container.
The description given by you indicates that the binding has been done one way only i.e. from workflow container to the task container. It should also be from the task container to the workflow container.
Since it is not able to get an instance of the '_ATTACH_OBJECTS' it is giving an error.
Regards,
Sameena -
Hello Experts,
I am a workflow novice, just starting out.
I have copied the standard PO release workflow - WS20000075 and inserted a send mail step before activity "Release of purchase order". This was because I would like to send the PO as a PDF attachment to the approver.
The send mail step works fine (i have custom object and method to attach and send mail), it sends out the mail with the attachment correctly, but the work item is in "ready state" and needs to be manually "completed" for the workflow to proceed. After this, the workflow proceeds perfectly.
The send mail is marked as a background task and synchronous object method.
What do i need to do for the "Release of purchase order" to happen as soon as the email has been sent out?
Thanks a lot for the help.
Regards,
Parag.Hello Ravi,
Thanks for the prompt reply, there are no erros in the workflow log.
SWU3 was definitely done, standard PO Release workflow works fine and so do other ones. Its just that I copied the standard and inserted a new step.
Do I somehow need to "terminate" the send mail step for the workflow to move over to the next activity ?
Regards,
Parag. -
SEND MAIL STEP IN WORKFLOWS.
hi gurus,
The send mail step sends a notification to the sap inbox of the user. This step works fine in a client, whereas it fails in another......I am not aware of the reason.
Regards,
Sukumar.hi,
please check the agent finding rule is failed in the log or the background job is scheduled properly inorder to schedule or delver the mails using the transaction : swnconfig if it EP 5.0 or above.
if it is issue with the workflow like buffer problem, then try this technique
You have changed your workflow template in client 000. If you look to the workflow definition in another client with SWDD, then you see the newest version as just maintained in client 000. But at runtime, the old (former) version of the workflow definition is used.
Cause:
When activating a workflow template, then also some client specific data is replicated from client 000 to the other clients. In this replication there is currently an error. I just talked to a workflow colleague. The problem we have observed seems to be just the tip of an iceberg ... . They are working on the issue(s) related to this.
Workaround:
Execute function module SWD_WFD_REPLICATE_FROM_9999 in the client, you need to have the newest template definition. Enter your workflow template ID (with pattern "WSxxxxxxxx") in parameter IM_TASK and execute. Make sure that you do not lock the template in SWDD.
Then you also (may) need to execute transaction SWU_OBUF to synchronize the buffer
i hope this answers your query.
Regards,
Saujanya -
Send mail step in local workflow
Hi Experts,
I have inserted a send mail step in my local workflow. But while executing the workflow rather than sending mail my workflow stops with status In process in send mail step. In graphical log its displaying as "No agent found" for send mail step. But i have assigned workflow initiator as agent. But other than send mail if i use other steps like user decision or activity in local workflow, wokflows proceeds with execution and sets to status completed. Should i not use send mail in local workflow step?
Things i have done:
1. I have mail workflow as general task from PFTC.
2. Tried with SWU_OBUF
3. Correctly assigned WF_INITIATOR as expression for send mail.
Kindly help me in this regard.
KR,
S BharathDear Bakker,
Sorry for the confusion. In send mail I tried with 2 options,
1. I directly gave expression as WF_INITIATOR
2. I created a workflow container element with type SWHACTOR and assigned a user id as initial value.
In both cases I am not getting send mail icon and status mail sent (one that usually comes for a send mail step in log) but instead i am getting an activity icon displayed with status ready. But there is no agent icon displayed (usually we click this to find the assigned agent). So the status of the workflow remains as In process.
KR,
S Bharath -
Regarding Mail step in a workflow.
Hi All,
I have a Mail step in the work flow and the mail needs to be send to all people in a particular position. But the position number is not a static one it is determined dynamically in back ground step and is available in an element of the workflow container.
The problem is when i choose position in the Agents i am not able to assign the workflow container element.
The WF container element refers to: SWHACTOR-OBJID
Could anyone please tell me the solution.
Points are definite.
Thanks & Regards,
Goutham.Hi Umang,
Thanks for your reply. I have 2 doubts about this.
1.) Is it fine if I change the event of this standard workflow itself. i.e. from RELEASESTEPCREATED to RELEASED ?
2.)If I create a customised workflow & if I change the event from RELEASESTEPCREATED to RELEASED then will it send the mail to PO releaser for each release, because the current process to send mail to each releaser is a must, only the confirmation for each PO reelase should be stopped.
Please suggest .
Maybe you are looking for
-
Cisco any connect does not reconnect to backup ASA
Hi In Cisco ASA ssl vpn using ANY connect, I have a question on ASA failover. There is an option in the ASDM (AnyConnect Client profile) where one can set a number of backup ASAs in case the primary ASA goes down, So Client can connect to backup ASA
-
c:forEach use .......need help
I am making a form of registering details of competitive exams.in this i am using the jstl for fetching the values fromthe database like qualification table is master table and the eligibilty table . these two tables are drop down list and depend on
-
how much does a person have to custom when importing out iphone 3gs/iphone 4/ipad 2 from USA
-
Photoshop elements 8 orginizer wont run on win 7
Just got my New PSE8 8 hoping it would identify my watched folders unlike PSE7. I can get the editor to run. But when I try to select the Orginizer it starts thje pannel comes up for approx 10 sec then goes away. I can not get it to come back. I see
-
RSRV check correct error in run in background
Hi All, can we run RSRV correct error in backgroud? if so, how? thanks in advance! Alden