You need to sign in to do that
Don't have an account?
Call Email Alert (template) from Apex
Is there a way to call an existing Email alert and pass it a record value for the merge fields? The object generating the email alert is a custom object called Account_Counselor__c. This alert is sent to myself and another admin when a APEX CLASS attempts to add a UserPackageLicense but there are no licenses available from PackageLicense. This alert will let us know that we need to buy more licenses. I already have the email alert setup and it works fine from a Visual Flow but I can't figure out how to call it from APEX as well.
You can use the below code to send Email throug Apex class:
Let me know if you have any issue or if you want any other help.
Thanks,
Abhishek