• tom sanches
  • NEWBIE
  • 10 Points
  • Member since 2021

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 2
    Questions
  • 2
    Replies
I have a trigger that updates a custom variable. (after insert/update/delete). This works, but I want the trigger to fire and update the variable for all entries. But so that my records are not updated, inserted and deleted

I tried to use the EmailTemplate object to get my template by id, but I get the error "Illegal assignment from List <EmailTemplate> to List <EmailTemplate>". Maybe there are other ways?

List<EmailTemplate> emailTemplate = [Select Subject, Body FROM EmailTemplate where  Id='TemplateId'];

Thank you in advance!
I have a trigger that updates a custom variable. (after insert/update/delete). This works, but I want the trigger to fire and update the variable for all entries. But so that my records are not updated, inserted and deleted

I tried to use the EmailTemplate object to get my template by id, but I get the error "Illegal assignment from List <EmailTemplate> to List <EmailTemplate>". Maybe there are other ways?

List<EmailTemplate> emailTemplate = [Select Subject, Body FROM EmailTemplate where  Id='TemplateId'];

Thank you in advance!