I'm using Newtonsoft.Json package and after I deserialize some json object, I place the resulting string in a listBox. I noticed that if the text contains characters such as single quote, in my listbox the added text contains the value ’. I read that this is due to unicode or UTF8 encoding of the original string, but I don't know how to translate it so that my listBox will show the proper way.
I expect it is necessary to use a Decoding to UTF8 or Unicode?
jsonData = JsonConvert.DeserializeObject(sJsonCode);
foreach (var message in jsonData["messages"])
{
string body = message.body.ToString(); // if message.body contains single quotes, they will be displayed as ’
listBox1.Items.Add(body);
}