473,230 Members | 4,199 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,230 software developers and data experts.

Problem displaying special characters

Hi,

I've got a problem with displaying texts with turkish characters.

There is a website administration system, which is developed using ASP
(VBScript) and ADO. This system is being used for inserting product
informations in to a ms-sql database.

There is another webbased application, which is developed using ASP.NET and
ADO.NET (C#). For this second application there is a separate ms-sql
database but the data on the first database is also being accessed and
displayed and that is exactly where my problem occures. The data, which was
written in to the database by the first application (ADO) can not be read by
the second application (ado.net) properly. Some of the turkish characters
are displayed as questionsmarks etc. The field at the database is NVARCHAR
(unicode).

Is there a way setting the encoding for a dataadapter before calling the
fill method? Or is there another workarround for this problem? Thanks in
advance.

Kivanc Toker
TUM Group IT Soluotions

Nov 19 '05 #1
4 3446
Does it mean that whatever the DataAdapter fills contains incorrect
characters or are they just displayed wrongly afterwards?
Best regards,

Henrik Dahl

"Kivanc Toker" <kt****@flashmail.com_NOSPAM> wrote in message
news:eG**************@TK2MSFTNGP10.phx.gbl...
Hi,

I've got a problem with displaying texts with turkish characters.

There is a website administration system, which is developed using ASP
(VBScript) and ADO. This system is being used for inserting product
informations in to a ms-sql database.

There is another webbased application, which is developed using ASP.NET and ADO.NET (C#). For this second application there is a separate ms-sql
database but the data on the first database is also being accessed and
displayed and that is exactly where my problem occures. The data, which was written in to the database by the first application (ADO) can not be read by the second application (ado.net) properly. Some of the turkish characters
are displayed as questionsmarks etc. The field at the database is NVARCHAR
(unicode).

Is there a way setting the encoding for a dataadapter before calling the
fill method? Or is there another workarround for this problem? Thanks in
advance.

Kivanc Toker
TUM Group IT Soluotions

Nov 19 '05 #2
Hi,

"Henrik Dahl" <He********@community.nospam> wrote in message
news:u%****************@TK2MSFTNGP09.phx.gbl...
Does it mean that whatever the DataAdapter fills contains incorrect
characters or are they just displayed wrongly afterwards?


When I make a simple search query in VS.NET, the information returned
contains invalid chars, which means the data inserted by ADO seems somehow
incorrect. But I can not say it for sure, because there is no turkish ms-sql
server version, which displays the texts correctly as we use them in our
language. But the first application (asp-ado-mssql server) displays the same
data correctly.

I know, what you think with "or are they just displayed wrongly afterwards".
I also use the required request, response and file encodings in web.config,
which is like:

<globalization

requestEncoding="ISO-8859-9"

responseEncoding="ISO-8859-9"

fileEncoding="ISO-8859-9"

culture="tr-TR"

uiCulture="tr-TR"

/>

Still need help...

Thank you..

Kivanc Toker

TUM Group IT Solutions
Nov 19 '05 #3
Got new informations about the problem.

http://forums.asp.net/518209/ShowPost.aspx

The most interesting part is :

"CAUSE:
The reason I found out was that each gb2312 character I store in MSSQL 2000,
it convert to unicode, splitting the double-byte characters into single
bytes, then converting each single-byte based on the codepage in
windows-1252 to the corresponding unicode equivalent.
Legacy ASP works, because everything is converted back from unicode back
into single-byte "char" (vs double-byte "char" in ASP.net), and all we have
to do is to set the response.charset=gb2312 to get it to work.
However in ASP.net, the WebForm does conversion base on the webform codepage
and webform charset, including the web.config globalization
responseEncoding, requestEncoding and fileEncoding. Hence you have to
manually set the webform codepage to windows-1252, but webform charset has
to be set to gb2312. During page_load, you have to type in
"response.charset=nothing" to display the data from MSSQL with no problem.
"

The problem is I didn't get the solution. I have the same problem with
turkish characters and I still need help.

Thanks in advance..

Kivanc Toker
Nov 19 '05 #4
What if you set the encoding to "UTF-8" instead of "ISO-8859-9"?

Best regards,

Henrik Dahl

"Kivanc Toker" <kt****@flashmail.com_NOSPAM> wrote in message
news:eK***************@TK2MSFTNGP15.phx.gbl...
Hi,

"Henrik Dahl" <He********@community.nospam> wrote in message
news:u%****************@TK2MSFTNGP09.phx.gbl...
Does it mean that whatever the DataAdapter fills contains incorrect
characters or are they just displayed wrongly afterwards?
When I make a simple search query in VS.NET, the information returned
contains invalid chars, which means the data inserted by ADO seems somehow
incorrect. But I can not say it for sure, because there is no turkish

ms-sql server version, which displays the texts correctly as we use them in our
language. But the first application (asp-ado-mssql server) displays the same data correctly.

I know, what you think with "or are they just displayed wrongly afterwards". I also use the required request, response and file encodings in web.config, which is like:

<globalization

requestEncoding="ISO-8859-9"

responseEncoding="ISO-8859-9"

fileEncoding="ISO-8859-9"

culture="tr-TR"

uiCulture="tr-TR"

/>

Still need help...

Thank you..

Kivanc Toker

TUM Group IT Solutions

Nov 19 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: Mosher | last post by:
Hi all, I have an issue with php and/or mysql. I have a php form that writes "items" to a mysql database, including a description of the item. On the mysql server, "magic_quotes_gpc" is ON. I...
2
by: John Smith | last post by:
I have a table that contains a chunk of text, and the text commonly has special characters, such as "&amp;" or "–". To edit this text, there is a page where the text is dumped into a textarea....
12
by: Jeff S | last post by:
In a VB.NET code behind module, I build a string for a link that points to a JavaScript function. The two lines of code below show what is relevant. PopupLink = "javascript:PopUpWindow(" &...
2
by: David Scemama | last post by:
Hi, I'm looking for a way to display semi graphic characters in a multi line text control or in a rich text control. I've tried with all the characters of the extended ASCII table (code page...
5
by: Sakharam Phapale | last post by:
Hi All, I am using an API function, which takes file path as an input. When file path contains special characters (@,#,$,%,&,^, etc), API function gives an error as "Unable to open input file"....
16
by: Dany | last post by:
Our web service was working fine until we installed .net Framework 1.1 service pack 1. Uninstalling SP1 is not an option because our largest customer says service packs marked as "critical" by...
7
by: jitu78 | last post by:
Hi, I am displaying dynamic content in my flash. Dynamic data is coming from XML and in flash file, html entities are not showing right, strange characters are displaying there. Here is link,...
2
by: chike_oji | last post by:
Hello, I am displaying data retrieved from a database as a httpresponse in a webform. I noticed that some characters such as the comma (,), display as special characters in the web browser...
3
by: rhandoo | last post by:
Hi, I am facing the problem in displaying the special characters like ( ` ) GRAVE ACCENT in C# windows Application. I am using oracle as back end. In oracle database table the string contain...
3
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 3 Jan 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). For other local times, please check World Time Buddy In...
0
by: abbasky | last post by:
### Vandf component communication method one: data sharing ​ Vandf components can achieve data exchange through data sharing, state sharing, events, and other methods. Vandf's data exchange method...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: stefan129 | last post by:
Hey forum members, I'm exploring options for SSL certificates for multiple domains. Has anyone had experience with multi-domain SSL certificates? Any recommendations on reliable providers or specific...
0
Git
by: egorbl4 | last post by:
Скачал я git, хотел начать настройку, а там вылезло вот это Что это? Что мне с этим делать? ...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: Aftab Ahmad | last post by:
Hello Experts! I have written a code in MS Access for a cmd called "WhatsApp Message" to open WhatsApp using that very code but the problem is that it gives a popup message everytime I clicked on...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.