You need to sign in to do that
Don't have an account?
hamayoun65
Outbound Email using an email template
Hi
I know it's possible to send outbound email from an Apex Class using a template. But what if the template has merge fields? Will those merge fields be resolved correctly? For example, lets say I have a custom object called XXX, and I create a trigger to call an Apex Class whenever a record of that custom object is created. If the template has references to XXX merge fields, will these be resolved?
Thx,
Hamayoun
I know it's possible to send outbound email from an Apex Class using a template. But what if the template has merge fields? Will those merge fields be resolved correctly? For example, lets say I have a custom object called XXX, and I create a trigger to call an Apex Class whenever a record of that custom object is created. If the template has references to XXX merge fields, will these be resolved?
Thx,
Hamayoun
I tried using the email.setWhatIds(); method and got an error saying it was an invalid ID, and that only "Cases, Contracts, Contacts, Leads and Opportunities" can have their ID's used as WhatId's.
Can I have any confirmation on this??
I was trying it with the "Event" Object trying to have an email template with some Event merge fields, that's how I saw the error.
- Patrick
http://www.salesforce.com/us/developer/docs/apexcode/index.htm
Thanks for the reply there Rasmus. I figured it may be something like that :)