Issue with Drop down Items with special Characters

We are facing challenge while selecting values from a drop down on an web interface in case of item contains any special characters.

Actually, the special characters like & translated as & in html source.

I think in html source only for some special characters it will change so instead of convert the html source to plain text it’s better to replace those text.
& - &
" - "

  • >
    < - <
    String.Replace("&","&") - This will work for “&”

Actually , String gets translated in different set of characters and value which we want to find out does not appear as expected which causes problem.


This is what i write but it changed while posting. Hope it helps.

You can use HttpUtility class to convert HTML codes.

  • HttpUtitlity.HtmlEncode("&")

  • HttpUtitlity.HtmlDecode("&amp;")

The package is under System.Web