+ Start a Discussion
lvivaninlvivanin 

Create attachments in apex

My requirement is:

 

- create Case using Email-to-Case

- attach the Email attachments (if any) to the newly created Case as Attachments

 

is there a way i can attach the email attachments to the newly created Case in Apex?

 

Thanks in advance.

ShikibuShikibu
Perhaps this thread can get you started.
lvivaninlvivanin

Thank you Shikibu,

 

For the time being my requirement has slightly been changed - working with related e-mails is enough, do not need to attach the incoming e-mail attachment(s) to the newly created case as attachment ( Note & Attachments ....).

paul-lmipaul-lmi
if you start handling attachments, and your emailers use outlook, you're probably going to run into issues with the file format of teh attachments.  apparently outlook will send some wacky .dat file instead of the actual files, in some cases.  i dropped attachment handling due to this.
lvivaninlvivanin
hank you very much paul-lmi.

 

I found the solution at Appexchange:link

 

By installing this package I get the e-mail attachments as the Case Attachments (under Notes & Attachment)  - which was my initial requirement.