Answers.Body: <p>It requires some code but yes you can write an extension that uses this hook: <a href="https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_emailProcessorContact" rel="nofollow noreferrer">https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_emailProcessorContact</a></p>
  <p>The example given there is a bit dated but is similar to what you are trying to do. In that example, it defines 2 special tags that you can put on contacts to change how emails get filed (e.g. everyone with the same domain in their email as an org gets filed on the org that is tagged - like all sales reps at a company will have the emails filed on the company so they're all in one place).</p>
  <p>In your case, you could instead write code to look if the sender has a relationship to a child, and file it on the child.</p>
  <p>Another way to do this is use CiviCase, where the client is the child. And then any emails with the case id coded in the subject will get filed on the case, e.g. <code>[#1234]</code>, where 1234 is the case id. If you sent the initial email from within the case in the case roles section, then replies will automatically have the identifier in the subject.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2024-05-15T17:45:36.057Z
Answers.LastActivityDate: 2024-05-15T17:45:36.057Z
Answers.UserDisplayName: Demerit
Body: <p>Ok sorry this is going to be a bit long and we are very new to Civi so still finding our way around.</p>
  <p>In our old database we saved all communications to a clients records.  So if this was an email from a parent, professional or anyone else supporting or discussing the child they were all saved on that childs record.  This was for ease so we could see a communication trail</p>
  <p>We have got an Outlook/Civi integration, that allows us to save incoming emails to contact, but it will only bring up the contact that the email address is assigned to.</p>
  <p>Is there any way that we can save emails to a contact that we designate?  Hope that makes some sense</p>
  
Tags: <inbound-email>
Title: Saving emails to a different contact than the sender
ThreadText: # Saving emails to a different contact than the sender
  
  (Asked by: username_0 on 2024-05-15)
  
  Ok sorry this is going to be a bit long and we are very new to Civi so still finding our way around.
  
  In our old database we saved all communications to a clients records. So if this was an email from a parent, professional or anyone else supporting or discussing the child they were all saved on that childs record. This was for ease so we could see a communication trail
  
  We have got an Outlook/Civi integration, that allows us to save incoming emails to contact, but it will only bring up the contact that the email address is assigned to.
  
  Is there any way that we can save emails to a contact that we designate? Hope that makes some sense
  
  **Tags:** inbound-email
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2024-05-15. Score: 3
  
  It requires some code but yes you can write an extension that uses this hook: <https://docs.civicrm.org/dev/en/latest/hooks/hook_civicrm_emailProcessorContact>
  
  The example given there is a bit dated but is similar to what you are trying to do. In that example, it defines 2 special tags that you can put on contacts to change how emails get filed (e.g. everyone with the same domain in their email as an org gets filed on the org that is tagged - like all sales reps at a company will have the emails filed on the company so they're all in one place).
  
  In your case, you could instead write code to look if the sender has a relationship to a child, and file it on the child.
  
  Another way to do this is use CiviCase, where the client is the child. And then any emails with the case id coded in the subject will get filed on the case, e.g. `[#1234]`, where 1234 is the case id. If you sent the initial email from within the case in the case roles section, then replies will automatically have the identifier in the subject.
  
  
  ---
  
  