function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Ferhat CHETOUANIFerhat CHETOUANI 

workflow case closed

Hi everybody,

I'd like to send an email when the case is closed.

My object is " survey invitation " that I linked with a case thanks to "lookup relationship".

So if someone can send me the "formula" to put in rule criteria section it would be really nice.

Have a nice day.

User-added image
AshishkAshishk
When do you want to send mail? When case is closed or on insert / update of survey invitation?
Ferhat CHETOUANIFerhat CHETOUANI
Thanks for your answer Ashishk. I'd like to send mail when the " status changed" for example the status is on " working" then I edit it to put on "closed" then the customer receive directly the mail.
Bhargavi TunuguntlaBhargavi Tunuguntla
Hi Ferhat

Try the below condition in the formulae criteria:
 
contains(text(Case__r.Status),'closed')

or You can even try the below:
 
ISPICKVAL( Case__r.Status , 'Closed')

Thanks.
AshishkAshishk
Create workflow rule on Case object, select Evaluation Criteria as "created, and any time it's edited to subsequently meet criteria" and update critria to ISPICKVAL(Status, "closed").

This should work.
Ferhat CHETOUANIFerhat CHETOUANI
Thanks for your answer. I tried your formulas but it's weird because it works well with "case object" but when I tried the same thing with "survey invitation object" I receive nothing in my email inbox.

Do you have an other idea to create a formula with "survey invitation object" that when the case it's closed I receive the email.

As you can see in the second picture maybe we can create a formula with "created by"

User-added image
User-added image
AshishkAshishk
If I am getting requirment, you want workflow on "survey invitation", which is a child of Case. When Case is closed you want to send emails to Survey invitations.

We need to do few more things to achive this:-
  1. Create a custom field on survey invitation, i.e. a simple checkbox
  2. Keep workflow with criteria ISPICKVAL( Case__r.Status , 'Closed') on survey invitation
  3. Create a process builder on case when it is closed and update survey invitation records i.e. checkbox
  4. Now your child records are updated, so workflow will trigger and send mail
Thanks,
Ashish
Bhargavi TunuguntlaBhargavi Tunuguntla
I think your scenario is: When you change a case status to 'closed' then all the related record owners of survey invitation object should be sent a mail.

If that's the case you cannot do it with workflow.Trying writing a trigger on case and when case updates to 'Closed' get all the related survey invitation and send email.

or

When case is 'Closed' update some field in survey invitation object(using workflow/process builder) and the workflow will get automatically invoked.

Thanks
Ferhat CHETOUANIFerhat CHETOUANI
Ashishk I followed your steps but I received this error message --> We can't save this record because the “testsurvey v3” process failed. Give your Salesforce admin these details.

Do you have an email adress I can show you how I did it.
AshishkAshishk
You are on skype? I can search you by name.
Ferhat CHETOUANIFerhat CHETOUANI
yes my skype --> chetouani.ferhat