4

I have gotten this error in production

SINGLE_EMAIL_LIMIT_EXCEEDED

I am sure i have maxed out the daily email limit of 1 000

limit info https://help.salesforce.com/HTViewHelpDoc?id=limits_email_general.htm&language=en_US

from that page it states "There’s no limit on sending individual emails to contacts, leads, person accounts, and users in your organization directly from account, contact, lead, opportunity, case, campaign, or custom object pages"

i want be clear if i can in my apex code query contact objects and send them an email and it will not count against the limit

 Contact[] contactId = [select id Contacts]

  Messaging.MassEmailMessage email = new Messaging.MassEmailMessage();
   email.saveAsActivity = false;
    email.setTemplateId(templateId);
    email.setTargetObjectIds(contactId[]);
    email.setWhatIds(objectId[]);
    Messaging.sendEmail(new Messaging.MassEmailMessage[] {email});  
3

The documentation that you cited means that there is no limit to a user in your organization sending through the Salesforce UI on a Contact, Account, Lead, etc. detail page from Send An Email button on the Activity History related list. The daily email limit of 1,000 sending through apex still applies.

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.