Html.FromHtml

warning CS0618: ‘Html.FromHtml(string)’ is obsolete: ‘deprecated’

Recently, while supporting a team updating their dependencies on Xamarin.Android I found some code similar to the following:

Starting with API level 24, Html.FromHtml(string) is deprecated and Html.FromHtml(string, FromHtmlOptions) should be used instead.

Here’s how the code looks after updated:

Leave a Reply