472,779 Members | 1,825 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Reading and Displaying Japanese data in MS SQL Server using ASP

I am using MS SQL Server 2000 and 2005, IIS 5,0 and ASP. I am able to display data that has been selected from a Unicode column in the database in all languages except Japanese (I get question marks when the data is Japanese).

I can get Japanese to display when the text is static, i.e., embedded in the html, but have been unable to display it when it comes from the database.

When I use Access to view the table, I can see that the Japanese text is correct in the database. I have added the meta tag <meta http-equiv="Content-type" content="text/html;charset=utf-8"> as the first line following the <head> tag. My understanding is that I need something comparable in the ASP code. I tried adding the following (bolded line) at the top of the code:
Expand|Select|Wrap|Line Numbers
  1. <%@ Language=VBScript %>
  2. <%Option Explicit%>
  3. Response.ContentEncoding = Encoding.UTF8;
  4. <!-- #INCLUDE FILE="includes/aspConnection.asp" -->
Here's the code where I am getting the data for strModuleIntro:
(Note: I recompiled the stored procedure after I changed the column type to nvarchar),
Expand|Select|Wrap|Line Numbers
  1. Sub ProcessLogin()
  2.   Dim objCmd
  3.   Dim objRst
  5.   Set objCmd = server.CreateObject("ADODB.Command")
  7.   With objCmd
  8.         .ActiveConnection = objCnn
  9.         .CommandType = adCmdStoredProc
  10.         .CommandText = "ModuleIntro_By_Login_Language_ssp"
  11.         .Parameters.Append .CreateParameter("LanguageCode_sz", adVarChar, adParamInput, 3 , strLanguageCode)
  12.         .Parameters.Append .CreateParameter("LoginID_sz", adVarChar, adParamInput, 50, strSubmit)
  13.   End With
  15.   Set objRst = server.CreateObject("ADODB.Recordset")
  17.   With objRst
  18.     .Open objCmd, , adOpenStatic, adLockReadOnly
  20.     if .RecordCount > 0 then
  21.       strLogin = strSubmit
  22.       intModule = .Fields("CurrentModule_l")
  23.       strModuleIntro = .Fields("ModuleIntro_sz")
  24.       strDivDisplayModuleIntroStyle = "Display:Block;" 
  25.       Call DisplayModuleIntro(strModuleIntro, intModule)
  26.     else
  27.       strDisplayLoginProblemStyle    = "Display: block;"
  28.       Call DisplayUserUnknown(strLanguageCode)
  29.     end if
  31.     .Close
  32.   End With
Any help would be greatly appreciated!
Nov 1 '06 #1
1 3727
1,754 Expert 1GB
Hi there,

Do you have Asian Font Set installed in your server? Check it out.
Nov 1 '06 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

by: GPenn | last post by:
SQL 2000, latest SP. We currently have the need to store data from a UTF-8 application in multiple languages in a single database. Our findings thus far support the fact that single-byte and...
by: Benoit Martin | last post by:
in my windows app, I have some japanese text that I load from a text file and display on a label. No matter what type of encoding I try to use on the text file, the text always comes up as a bunch...
by: Doug Lerner | last post by:
I'm working on a client/server app that seems to work fine in OS Firefox and Windows IE and Firefox. However, in OS X Safari, although the UI/communications themselves work fine, if the...
by: prats | last post by:
I want to write a GUI application in PYTHON using QT. This application is supposed to take in Japanese characters. I am using PyQt as the wrapper for using QT from python. I am able to take input...
by: tony.pahl | last post by:
We are converting a data warehouse to a Unicode database to get ready for multilingual support. If we will have 95% of our data in English as we currently do, and less than 5% in other foreign...
by: DL | last post by:
Hi, Our school has an application in which : - Teachers enter comments through a web interface built in asp (not asp.net). - Comments are stored in a SQL server 2000 (in a nText field) -...
by: pardesiya | last post by:
Friends, I am having trouble displaying Japanese text within a textbox (or anywhere else) in an aspx page with .net 2.0 framework. Initial default text in Japanese displays perfectly but when I...
by: Kots | last post by:
Hi, I have an excel sheet, and have a column called Customer Name. This column contains data that is in different languages.. english, chinese, Japanese and Korean names. I need to import this...
by: Rina0 | last post by:
Cybersecurity engineering is a specialized field that focuses on the design, development, and implementation of systems, processes, and technologies that protect against cyber threats and...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 2 August 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
by: linyimin | last post by:
Spring Startup Analyzer generates an interactive Spring application startup report that lets you understand what contributes to the application startup time and helps to optimize it. Support for...
by: erikbower65 | last post by:
Here's a concise step-by-step guide for manually installing IntelliJ IDEA: 1. Download: Visit the official JetBrains website and download the IntelliJ IDEA Community or Ultimate edition based on...
by: DJRhino1175 | last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this - If...
by: Rina0 | last post by:
I am looking for a Python code to find the longest common subsequence of two strings. I found this blog post that describes the length of longest common subsequence problem and provides a solution in...
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
by: lllomh | last post by:
How does React native implement an English player?
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

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.