1

I would like to know if it's possible to disable sending of an email when the case is closed and when the owner of the case changes?

In the "support settings" for case, the checkbox "Notify Case Owners when Case Ownership Changes" is disabled.

So I don't understand why an email is sending to the owner when a case is closed or if the owner changes..

The email is sended since I developed an Apex trigger which set the user as owner when he changes the status of a case.

Can you help me please?

Regards Aurélien

1
  • look for possible WF rule(s) that sends email – pnoytechie Sep 24 '15 at 0:36
0

Try clearing out the Case Assigned Template in the Support Settings.

And/Or in your trigger try setting the DML Header properties, the following example is from the docs here.

Usage

Even though auto-sent emails can be triggered by actions in the Salesforce user interface, the DMLOptions settings for emailHeader take effect only for DML operations carried out in Apex code.

Account a = new Account(name='Acme Plumbing');

insert a;

Contact c = new Contact(email='jplumber@salesforce.com', firstname='Joe',lastname='Plumber', accountid=a.id);

insert c;

Database.DMLOptions dlo = new Database.DMLOptions();

dlo.EmailHeader.triggerAutoResponseEmail = true;

Case ca = new Case(subject='Plumbing Problems', contactid=c.id);

database.insert(ca, dlo);
1
  • Sorry for the late. I will test your response when I will have free time but thanks. I read several time the same thing on the internet so I think it is the solution. :) – Aurélien Laval Sep 29 '15 at 8:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.