Hello everybody
I'm trying to insert/update values in a database by using a detailsview.
It works fine if my input string consists of only characters like ( a-z, A-Z).
But i also need to use charachter like( aaoAAO), but these values are stored as
(å ä ö Å Ä Ö ) in the database, why
How can these values be validated so they are stored in a proper way
Regards Ylva
hi,
which database are you using
if it is sqlserver, just use nvarchar type for your fields types.
if you are using oracle, then is more complicated, because it is related with the language in which the database was installed.
Best Regards
by default, detailsview store the UNICODE value for every field, you can set HtmlEncode attribute to false in the Field element of DetailsView's Fileds in aspx page, like this:
<asp:DetailsView ID="DetailsView1" ...........>
<Fields>
<asp:BoundField DataField="f1" HeaderTextr="h1" HtmlEncode="false" />
.......
</Fields>
</asp:DetailsView>
Thanks for this help, it solved the problem