Error: Culture 'es' is a neutral culture. It cannot be used in formatting and parsing and therefore cannot be set as the thread

 

We get about 40 application errors shown below every day from our customers in other countries.  These seem to occur in pages we made using iSA (System Architect).  One for donations and one for listing our products.  I tried changing the globalization settings in the Web.config and in the page directive but nothing seems to help.

Any ideas?

Server Error in '/' Application.
--------------------------------------------------------------------------------

Culture 'es' is a neutral culture. It cannot 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.
 

Thanks

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Hi eja144, When I came

Hi eja144,

When I came accross this error a few months ago while programming our web site to handle iBO.NET. I found out that the problem was when I was assigning the cultural code to a session cultural value. The problem you are experiencing between Macintosh computers and the Microsoft.NET architecture. I found from my experience, Macintosh computers will use a generic cultural code such as 'en' when browsing a website instead of a language/country specific code such as 'en-us'. This causes the Microsoft.NET to through the "Culture 'XX' is a neutral culture" error message. Microsoft.NET uses the language/county codes to understand how a specific country will format a date for input and so forth.

One suggestion I can make is if you can not change the code is to disable client cultures is to force everyone to use your culture format. I believe you can do this by chaning the web.config's globalization settings to

 
Sean

<code>
<system.web>
 <globalization culture="en-us" enableClientBasedCulture="false"/>
</system.web>
</code>

 

ERROR: Culture 'fr' is a neutral culture

I will give that a try.  Our Web.config also has uiCulture so I will try setting it to "en-us" also.

Thanks

Culture Settings Known issues

What version are you on?  We have 4-5 SMR's with ASI on this issue they have made changes in several of the 15 versions but we have customers who continue to have issues.  Are you an international organization?  The culture settings control date but also how dollar amounts are displayed and formated based on the local representation.  The main issue we've had is that customers who experience these errors 1) don't see the amounts represented correctly - dues amount owed shows as 0.00 with certain culture settings, 2) trying to add an item to the cart gets an error "invalid amount" even when the correct amount is displaying, 3) customer unable to checkout.   Do you know what the end user is trying to do when you get these errors?  I would suggest trying to identify the user and contact them.  We have found that this issue spans multiple operating system (not just Macs), and browsers.  Do you get any more detailed information in the errors table?  Have you looked at the event logs on the IIS server for more information on the errors? 

We've seen most of these issue for international users but have seen them on US users also.  We've been able to reproduce the errors as a result of the Computers local / regional settings and browsers language settings -- specically when they do not match. 

Other errors we've run into... do you see any of these:

1) Culture name 'es-us' is not supported. Parameter name: name<br><br>

2) Could not load file or assembly 'App_Web_mzmndm_h, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.<br><br>

3) Culture name 'en-securid' is not supported. Parameter name: name<br><br>
 

I also ran across the following in Microsoft's .NET Framework Developer Center -- I believe this plays into the issue with both ASI and custom .NET development

IMIS does have a place to store the ISO Code...
Country_Names.ISO_3DIGIT_CODE
CountryRef.ISO3DigitCode

The Microsoft Artical (http://msdn.microsoft.com/en-us/library/atwc2921(VS.80).aspx) says that the ISO Code determines the Culture Settings:

~~~~~~~~~~~~~~~~~~~~
The RegionInfo name is one of the two-letter codes defined in ISO 3166 for country/region, or a specific, custom, or Windows-only culture name. Case is not significant; however, the Name, the TwoLetterISORegionName, and the ThreeLetterISORegionName properties return the specified code or culture name in uppercase.
~~~~~~~~~~~~~~~~~~~~
 

ASI blew off the idea that has anything to do with it.  iMIS has setting for ISO codes but ASI's responce was that "ISO codes are not used by any of the web components to control display. The settings come from the users Browser settings and in turn their windows settings."    even though the microsoft artical above clearly states that the ISO code determines the culture setting. 
 

We hammered tech support for almost a year, got a couple "fixes" in newer versions but in general did not get very far with it... we upgraded a couple times to test newer versions and that did help but it did not resolve the issue.  Sorry wish I had better news for you on it.

 

RE Culture settings known issue

Hi,
We are running version 15.1.1.3286.   When we contacted iMIS about this issue they said it was known but didn't know when it would be fixed.  At least that is what a co-worker told me.

We have a lot of customers in other countries.  We don't have to support anything but the dollar and we just had a customer call us because she was concerned that our donation page said she donated in pounds and that was more than she wanted to donate.  We assured her it was dollars despite what the page said.

Our customers are getting errors when they go to the product list page and also when they try to donate.  Some get the error when they go to their shopping cart. 

That is a good suggestion to contact the user.  We will do that.  I think it is a browser setting as the customer who was surprised to see she donated in pounds moved here from the UK many months ago.

I do look at the error logs.  I can't seem to copy the text to the clip board but it is having a problem in System.Globalization.CultureInfo.CheckNeutral(CultureInfo culture) at System.Globalization.CultureInfo.get_NumberFormat() at etc etc on the CartPage product list getDisplayPrice. etc

I haven't seen any of the three errors below

1) Culture name 'es-us' is not supported. Parameter name: name

2) Could not load file or assembly 'App_Web_mzmndm_h, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. The system cannot find the file specified.<br><br>

3) Culture name 'en-securid' is not supported.

I'm hoping the change I made to the web.config will force our users to use 'en-us' regardless of their browser settings.  It would be nice to get this resolved before the holidays. 

Thanks

 

Re: Culture Settings known issue

The change to the Web.config didn't help now it says:

Error Message    Object reference not set to an insance of an object

Stack Trace       at IWC.UI.WebControls.CartPage.get_CultureInfo() at IWC.UI.WebControls.CartPage.GetDisplayPrice(Decimal price) at Asi.Bae.Web.Orders.ProductListWebUserControl.DisplayList(Int32 page)

 

That puts me out of ideas.

That puts me out of ideas.

Need some additional info

In a failing scenario, what is the browser being used, and what language(s) are defined in the browser (e.g., in IE8, Tools > Internet Options > Languages button)?

...paul