Manoj Bisht

Manoj Bisht

  • 0
  • 140
  • 0

French character being converted into diamond with a question mark

Sep 15 2021 9:54 AM

Hi,

In .NET Core Web API Special Characters of French being converted into black diamond with question mark into Email on Server but at localhost everything is ok

Example:- Conversion of special characters

Real Word:- Converted into Mail
d’avoir = d?avoir
à = ?
procédure = proc?dure

 

---------------------------------

What I have tried:

var msg = new SendGridMessage();
string to = objContractorOperationEmail.To;
msg.AddTo(to);
msg.SetSubject(objContractorOperationEmail.Subject);
msg.AddContent(MimeType.Html, objContractorOperationEmail.Body);
Send(msg);

public void Send(SendGridMessage msg)
{
var client = new SendGridClient(_mailConfig.Value.SendgridKey);
msg.From = new EmailAddress(_mailConfig.Value.FromEmail, _mailConfig.Value.FromName);
client.SendEmailAsync(msg);
}


Answers (2)