You need to sign in to do that
Don't have an account?
Jayesh Deo 2
I am trying to add PDF attach to email but mentioned error displayed for Line 81. Please help
Method does not exist or incorrect signature: void add(Messaging.EmailAttachment) from the type List<Messaging.EmailFileAttachment>
I am trying to add PDF attach to email but mentioned error displayed for Line 81. Please help
The complete code is not included in the question. So based on my understanding, looks like you are trying to use the add() method on a List<Messaging.EmailFileAttachment> object, which does not exist. To add a PDF attachment to an email, you need to use the add() method on an instance of Messaging.EmailFileAttachment.
This related example can help you:
If this information helps, please mark the answer as best. Thank you
All Answers
The complete code is not included in the question. So based on my understanding, looks like you are trying to use the add() method on a List<Messaging.EmailFileAttachment> object, which does not exist. To add a PDF attachment to an email, you need to use the add() method on an instance of Messaging.EmailFileAttachment.
This related example can help you:
If this information helps, please mark the answer as best. Thank you
Thanks for your Answer! It helped.
I updated below highlighted declared object and after that code ran without error.