Answers.Body: <p>I suspect this was an intended outcome ie, you do a search, you find your contacts, you use "Email - send/schedule via civimail" and that locks in the recipients.</p>
  
  <p>If at that point you decide your search was incorrect, then you need to start over.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-07-25T18:57:05.840Z
Answers.LastActivityDate: 2017-07-25T18:57:05.840Z
Answers.UserDisplayName: petednz - fuzion
Body: <p>When doing a contact search and using the action "Send email", a new draft mailing is created and a hidden group is assigned as recipients to the draft mailing. It is is displayed as "Search results" and has a different color.</p>
  
  <p>If I click on the cross to remove it from the recipients, I get a message <em>"This mailing was generated based on search results. The search results cannot be removed."</em>. Why is that? I looked at the code where this restriction is enforced, but couldn't see anything that would suggest why search results cannot be deleted.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-07-24T20:34:43.860Z
Comments.Text: Assuming you are on a recent version, please clarify your 'Send email'. There is no such action afaik. You have either "Email - send/schedule via civimail' or 'Email - send now to 50 or less'. Also can you clarify why, if you have done a search to find contacts to then send an email to, you then want to remove those contacts?
Comments.UserDisplayName: petednz - fuzion
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-07-25T09:05:15.563Z
Comments.Text: Yes sorry I wrote that out of my memory, I am talking about "Email - send/schedule via civimail". The use case is mainly: the user realizes while composing the email that the search criteria were not correct, and want to re-do the search (We have an extension to associate search results to an existing draft). They may also want to replace the search results by a group they have prepared earlier.
Comments.UserDisplayName: Djizeus
Tags: <search-results><mailing>
Title: Why can Search results not be removed from mailing recipients?
ThreadText: # Why can Search results not be removed from mailing recipients?
  
  (Asked by: username_0 on 2017-07-24)
  
  When doing a contact search and using the action "Send email", a new draft mailing is created and a hidden group is assigned as recipients to the draft mailing. It is is displayed as "Search results" and has a different color.
  
  If I click on the cross to remove it from the recipients, I get a message *"This mailing was generated based on search results. The search results cannot be removed."*. Why is that? I looked at the code where this restriction is enforced, but couldn't see anything that would suggest why search results cannot be deleted.
  
  **Tags:** search-results, mailing
  
  > **Comments:**
  > **username_1**: Assuming you are on a recent version, please clarify your 'Send email'. There is no such action afaik. You have either "Email - send/schedule via civimail' or 'Email - send now to 50 or less'. Also can you clarify why, if you have done a search to find contacts to then send an email to, you then want to remove those contacts?  
  > **username_0**: Yes sorry I wrote that out of my memory, I am talking about "Email - send/schedule via civimail". The use case is mainly: the user realizes while composing the email that the search criteria were not correct, and want to re-do the search (We have an extension to associate search results to an existing draft). They may also want to replace the search results by a group they have prepared earlier.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-07-25. Score: 1
  
  I suspect this was an intended outcome ie, you do a search, you find your contacts, you use "Email - send/schedule via civimail" and that locks in the recipients.
  
  If at that point you decide your search was incorrect, then you need to start over.
  
  
  ---
  
  