I am trying to create a flow that can duplicate an email message including attachment onto a new case from an existing case that has been closed.

So far I have been able to create the flow as attached, which create a new case from existing case as well as copying the email message over, however it doesn't seems to copy the attachment over and the flow ran without issue.  Does any one know what I have done wrong?

1) Part of the Flow enter image description here

2) Fast Lookup on Email attachment from the Email ID from the closed case. enter image description here enter image description here

3) Loop thru the list of attachments enter image description here

4) Assigning the SOObject variabe (var_CurrentAttachment) to the new SOObject variable NewAttachment, including the new email message ID as the parentID of the attachment. enter image description here

5) Adding each of the NewAttachment SOObject variable to the NewAttachmentCollection SOObject Collection variable (cater for multiple attachments) enter image description here

6) Fast Create an attachment using SOObject collection variable NewAttachmentCollection. enter image description here

Case and Email are both successfully created however attachment is not in the email created on the new case. Can you tell me what I have done wrong in this Visual Flow?

  • Does everyone have an answer for this issue. I need to 'link' made the parent Id of an attach of email to case to another object...And I made a similar schema in flow. However got error on assignment"Error element Assign_Attach_fields (FlowAssignment). You referenced an unsupported field type called "Text Area" using the following field: null" – user62071 Nov 15 '18 at 22:17

According to your flow, when you are creating New Case store that Case Id into a variable say var_caseId.

That var_caseId to be assigned as Parent of the newly created Attachment record.

Apparently looking at the flow in this step you are wrongly assigning the ParentId to {!var_NewEmailId}. It should be like this to{!var_caseId}.

(4) Assigning the SOObject variable (var_CurrentAttachment) to the new SOObject variable NewAttachment, including the new email message ID as the parentID of the attachment.


| improve this answer | |
  • Hi Santanu, thank you for the feedback but I would like to add the new attachment to the newly created Email instead of the case, should I still be using the new case ID as the parent ID of the attachment? – Apple Apr 2 '17 at 23:34
  • First of all email to be attached to the case, though parent id. Then if you try to attach any attachments related to email then use the parent I'd of email re cord to add attachments – Santanu Boral Apr 3 '17 at 0:30
  • I have used the var_NewEmailId as the parent ID as per screen shot and perform a fast create to add attachment after the case and email has been created. This resulted in New Case and New Email created only with attachment not created to the new email. – Apple Apr 3 '17 at 13:26

Not the answer you're looking for? Browse other questions tagged or ask your own question.