I am developing website by using ASP.net. In there I am firing several emails to user. Probelem is all the emails are grouping( Threading) I want to stop this.
I found a post regarding this on
Force emails not to be grouped into conversations
In there it says
set X-Entity-Ref-ID header (no value needed). This is what Google+ notifications do.
change the sender email (you can use From: [email protected]). This is what Facebook notifications
do.
I dont think 2nd idea is a good thing. But I want to try the first thing. How to do it? Where I can find this attribute?
I'm using nuget package Postal for sending emails in both html and text formats. For that, there is an email header file (holding "from" and "to" info). Adding
X-Entity-Ref-ID: HeaderId
, where HeaderId is a guid, to this file (before theFrom:
andTo:
parameters) works. Give a unique reference value to X-Entity-Ref-ID, rather than no value.You may well not be using Postal but this approach may work for other packages as well.
In the Controller:
and then, in the email header file:
with the EmailModel defined as: