473,320 Members | 1,887 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,320 software developers and data experts.

Globalization problem

FM
Hi,

I use the following code to set the current culture.

If Not IsNothing(Session("language")) Then
System.Threading.Thread.CurrentThread.CurrentCultu re = New
System.Globalization.CultureInfo(Session("language ").ToString)

End If

If the users's browser (IE) is configured in the languages section to
support Japanese (ja) I get the following error when I go on the page:

Culture "ja" is a neutral culture. It can not be used in formatting and
parsing and therefore cannot be set as the thread's current culture.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.NotSupportedException: Culture "ja" is a neutral
culture. It can not be used in formatting and parsing and therefore cannot
be set as the thread's current culture.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[NotSupportedException: Culture "ja" is a neutral culture. It can not be
used in formatting and parsing and therefore cannot be set as the thread's
current culture.]
System.Globalization.CultureInfo.CheckNeutral(Cult ureInfo culture) +110
System.Threading.Thread.set_CurrentCulture(Culture Info value) +17
ASPNetPortal.DesktopDefault.Page_Init(Object sender, EventArgs e) +208
System.Web.UI.Control.OnInit(EventArgs e) +67
System.Web.UI.Control.InitRecursive(Control namingContainer) +235
System.Web.UI.Page.ProcessRequestMain() +171

Any idea why this is hapening and what should I do would be much
appreciated.
Thanks,
Florian Marinoiu




Nov 17 '05 #1
4 3567
Florian,

Try providing the region information as well in order to create a specific
culture rather than a neutral culture. e.g.: "ja-JP instead" of just "ja".

HTH,
Nicole
"FM" <_@mail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
Hi,

I use the following code to set the current culture.

If Not IsNothing(Session("language")) Then
System.Threading.Thread.CurrentThread.CurrentCultu re = New
System.Globalization.CultureInfo(Session("language ").ToString)

End If

If the users's browser (IE) is configured in the languages section to
support Japanese (ja) I get the following error when I go on the page:

Culture "ja" is a neutral culture. It can not be used in formatting and
parsing and therefore cannot be set as the thread's current culture.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.NotSupportedException: Culture "ja" is a neutral
culture. It can not be used in formatting and parsing and therefore cannot
be set as the thread's current culture.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[NotSupportedException: Culture "ja" is a neutral culture. It can not be
used in formatting and parsing and therefore cannot be set as the thread's
current culture.]
System.Globalization.CultureInfo.CheckNeutral(Cult ureInfo culture) +110
System.Threading.Thread.set_CurrentCulture(Culture Info value) +17
ASPNetPortal.DesktopDefault.Page_Init(Object sender, EventArgs e) +208
System.Web.UI.Control.OnInit(EventArgs e) +67
System.Web.UI.Control.InitRecursive(Control namingContainer) +235
System.Web.UI.Page.ProcessRequestMain() +171

Any idea why this is hapening and what should I do would be much
appreciated.
Thanks,
Florian Marinoiu




Nov 17 '05 #2
Florian,

Try providing the region information as well in order to create a specific
culture rather than a neutral culture. e.g.: "ja-JP instead" of just "ja".

HTH,
Nicole
"FM" <_@mail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
Hi,

I use the following code to set the current culture.

If Not IsNothing(Session("language")) Then
System.Threading.Thread.CurrentThread.CurrentCultu re = New
System.Globalization.CultureInfo(Session("language ").ToString)

End If

If the users's browser (IE) is configured in the languages section to
support Japanese (ja) I get the following error when I go on the page:

Culture "ja" is a neutral culture. It can not be used in formatting and
parsing and therefore cannot be set as the thread's current culture.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.NotSupportedException: Culture "ja" is a neutral
culture. It can not be used in formatting and parsing and therefore cannot
be set as the thread's current culture.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[NotSupportedException: Culture "ja" is a neutral culture. It can not be
used in formatting and parsing and therefore cannot be set as the thread's
current culture.]
System.Globalization.CultureInfo.CheckNeutral(Cult ureInfo culture) +110
System.Threading.Thread.set_CurrentCulture(Culture Info value) +17
ASPNetPortal.DesktopDefault.Page_Init(Object sender, EventArgs e) +208
System.Web.UI.Control.OnInit(EventArgs e) +67
System.Web.UI.Control.InitRecursive(Control namingContainer) +235
System.Web.UI.Page.ProcessRequestMain() +171

Any idea why this is hapening and what should I do would be much
appreciated.
Thanks,
Florian Marinoiu




Nov 17 '05 #3
Florian,

Try providing the region information as well in order to create a specific
culture rather than a neutral culture. e.g.: "ja-JP instead" of just "ja".

HTH,
Nicole
"FM" <_@mail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
Hi,

I use the following code to set the current culture.

If Not IsNothing(Session("language")) Then
System.Threading.Thread.CurrentThread.CurrentCultu re = New
System.Globalization.CultureInfo(Session("language ").ToString)

End If

If the users's browser (IE) is configured in the languages section to
support Japanese (ja) I get the following error when I go on the page:

Culture "ja" is a neutral culture. It can not be used in formatting and
parsing and therefore cannot be set as the thread's current culture.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.NotSupportedException: Culture "ja" is a neutral
culture. It can not be used in formatting and parsing and therefore cannot
be set as the thread's current culture.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[NotSupportedException: Culture "ja" is a neutral culture. It can not be
used in formatting and parsing and therefore cannot be set as the thread's
current culture.]
System.Globalization.CultureInfo.CheckNeutral(Cult ureInfo culture) +110
System.Threading.Thread.set_CurrentCulture(Culture Info value) +17
ASPNetPortal.DesktopDefault.Page_Init(Object sender, EventArgs e) +208
System.Web.UI.Control.OnInit(EventArgs e) +67
System.Web.UI.Control.InitRecursive(Control namingContainer) +235
System.Web.UI.Page.ProcessRequestMain() +171

Any idea why this is hapening and what should I do would be much
appreciated.
Thanks,
Florian Marinoiu




Nov 17 '05 #4
Florian,

Try providing the region information as well in order to create a specific
culture rather than a neutral culture. e.g.: "ja-JP instead" of just "ja".

HTH,
Nicole
"FM" <_@mail.com> wrote in message
news:%2****************@TK2MSFTNGP11.phx.gbl...
Hi,

I use the following code to set the current culture.

If Not IsNothing(Session("language")) Then
System.Threading.Thread.CurrentThread.CurrentCultu re = New
System.Globalization.CultureInfo(Session("language ").ToString)

End If

If the users's browser (IE) is configured in the languages section to
support Japanese (ja) I get the following error when I go on the page:

Culture "ja" is a neutral culture. It can not be used in formatting and
parsing and therefore cannot be set as the thread's current culture.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.

Exception Details: System.NotSupportedException: Culture "ja" is a neutral
culture. It can not be used in formatting and parsing and therefore cannot
be set as the thread's current culture.

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[NotSupportedException: Culture "ja" is a neutral culture. It can not be
used in formatting and parsing and therefore cannot be set as the thread's
current culture.]
System.Globalization.CultureInfo.CheckNeutral(Cult ureInfo culture) +110
System.Threading.Thread.set_CurrentCulture(Culture Info value) +17
ASPNetPortal.DesktopDefault.Page_Init(Object sender, EventArgs e) +208
System.Web.UI.Control.OnInit(EventArgs e) +67
System.Web.UI.Control.InitRecursive(Control namingContainer) +235
System.Web.UI.Page.ProcessRequestMain() +171

Any idea why this is hapening and what should I do would be much
appreciated.
Thanks,
Florian Marinoiu




Nov 17 '05 #5

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

Similar topics

3
by: Xavier MT | last post by:
Hi, I have a site that has some text in spanish and it doesn't display well, for example with a ñ it displays some weird boxes, can anyone help me or point me to some help
0
by: FM | last post by:
Hi, I use the following code to set the current culture. If Not IsNothing(Session("language")) Then System.Threading.Thread.CurrentThread.CurrentCulture = New...
1
by: Michael | last post by:
Hi, I'm developing an ASP.NET application that uses globalization. The language information is stored in .resx-files. For development I use VS.NET 2003, IIS v5.1, Framework v1.1, Windows XP...
1
by: francois | last post by:
hi, I have an ASP.NET application with a piece of code that looks like this: (it is a VB.NET snippet) Thread.CurrentThread.CurrentCulture = New CultureInfo(Session.Item("Culture").ToString)...
11
by: Cor Ligthert | last post by:
Hello everybody, Jay and Herfried are telling me every time when I use CDate that using the datetime.parseexact is always the best way to do String to datetime conversions. They don't tell why...
2
by: jason | last post by:
DOTNET 2.0 VS 2005. My client is saying August 13,2006.. julian date should equal 225. Here's what I'm doing: <%@ Import Namespace="system.globalization" %> <script language="VB"...
1
by: =?Utf-8?B?S3Jpc2huYQ==?= | last post by:
Hi, I am krishna in India.I developed Asp.net application the default culture settings is <globalization culture="en-US" uiCulture="en-US"/>.I need change globalization settings for UK.How to...
2
by: Terry Olsen | last post by:
I'm a bit confused on how to make my app work in all cultures, particularly with parsing the date out of a string. I read dates from different web sites. The formats I've run into include...
5
by: Basildk | last post by:
Hi. I have a strange problem. We have an asp.net application running on several server with different setups. On 2 of our servers we experience that the globalization settings are misbehaving....
0
by: Sparkiee | last post by:
Hi, A lil bit of help required from you guys, I am trying to make a windows service that will also focus on globalization, the problem i am facing is when i am trying to put globalization code in...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

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.