0

I have a Force.com site with pages which create Cases. They are not using Web-to-case. If I require to use Case Response Rules to send autoresponse rules I have questions in relation to this 1) Should these fire also for cases not created via an API call or Web-To-Case, therefore firing on a case created via a Force.com Site 2) How do I debug this; I've tested the above and if 1) is a valid scenario the case auto response emails are not being sent and no debug log entry has appeared even though the criteria for the auto response rule should be met.

Any advice or clarifications on the above would be appreciated.

Thanking you in advance.

3

By default they don't unless you set it to via DML Options and the EmailHeader.triggerAutoResponseEmail property. For example:

Database.DMLOptions dmo = new Database.DMLOptions();
dmo.EmailHeader.triggerAutoResponseEmail= true;

Case c = new Case(Origin='Web', Subject='My Question here' );
c.setOptions(dmo);
insert c;

More details on the developer docs here

  • Thank you. By setting .EmailHeader.triggerAutoResponseEmail = true; is works and sends an email. – RedQueries Jun 1 '16 at 23:26
  • On another note, do you know if an email field can be used for the recipient email instead of sending to an associated contact. Similar to how this can be done with a workflow rule? Thanks! – RedQueries Jun 1 '16 at 23:27

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.