ToastNotification
ToastNotification copied to clipboard
How is the method using in a foreach?
If the method is in a foreach, it doesn't work.
I am unsure if you were able to fix. I also had the same issue. But I ended up encoding the Html. I saw that in my case the single quotes were returned which is not handled in the library. So used below code which is working for me
var errormessage = ""; var htmlEncoder = HtmlEncoder.Create(new TextEncoderSettings());
foreach (var error in result.Errors) { errormessage = htmlEncoder.Encode(error.Description); _notify.Error(errormessage); }
The code I gave works for me. If you get an error, write and I will help you.