I have stored special characters in a database (µ) and want to display these in a dropdownlist on a page.
When I retrieve the records from the db, it is writing the special character as ?? when it should be µ It even does the same if I write it out to the screen.
Other special characters such as € appear fine when written to the screen.
I've tried using Server.HTMLEncode in my data access function:-
where weightList is a Dictionary<int, string> object and HTMLDecode in my page. The weight value from my stored procedure is:-Code:while (rs.Read()) { weightList.Add(Convert.ToInt32(rs["id"]), HttpContext.Current.Server.HtmlEncode((string)rs["weight"])); }
When I call the sp in Query Browser, the characters appear fine, but I can't get them to appear either in the dropdown or on the screen correctly.Code:CONCAT(A.Amount,B.ShortName) AS weight



LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks