System.Globalization.CultureNotFoundException: Culture is not supported - c#

I develop in C# an site that on my computer works on all 3 browsers(FireFox, IE and Chrome).
On other computer works on IE but on FireFox received following error:
"Culture is not supported.
Parameter name: name
English is an invalid culture identifier.
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.Globalization.CultureNotFoundException: Culture is not supported.
Parameter name: name
English is an invalid culture identifier.
Source Error:
Line 29: if (!String.IsNullOrEmpty(langValue))
Line 30: {
Line 31: UICulture = langValue;
Line 32: //Culture = langValue;
Line 33: "
I received same error on other computer on IE and Chrome but not on FireFox.
All browsers are updated to the newest versions and are on Windows 7.
Can anyone give me a hint or a solution for this problem, please?
Thanks

You may try to do this:
Go to the Debug menu -> Exceptions... and check that everything is unchecked for the Exception list.
Also try to delete all the files from the ASP.NET temporary folders present at the below location:
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files

English is not an identifier. Try with "en" or "en-US"

Related

Program fails to start; Event Viewer logs ConfigurationsErrorException

Issue: On my development machine, everything works fine. However, when I copy the executable to the server, my program doesn't start
What I've done so far: I checked the event viewer and the error stack looks like this:
Application: Project.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Configuration.ConfigurationErrorsException
Stack:
at System.Configuration.ClientConfigurationSystem.EnsureInit(System.String)
at System.Configuration.ClientConfigurationSystem.PrepareClientConfigSystem(System.String)
at System.Configuration.ClientConfigurationSystem.System.Configuration.Internal.IInternalConfigSystem.GetSection(System.String)
at System.Configuration.ConfigurationManager.GetSection(System.String)
at System.Configuration.ConfigurationManager.get_ConnectionStrings()
at Project.BaseService..ctor()
at Project.Service..ctor()
at Project.Program.Main()
I checked online and, most of the times, this error is generated by some misplacement of configSections on the .config files. To make sure this was not the case, I let both app.config and .exe.config files clean (only the section was there), but my program still didn't work.
Then, I generated a dump file from the failing process and here is where things get strange: the exception that is thrown when I'm calling ConfigurationManager.ConnectionStrings is "Configuration System failed to initialize", with a "The 'add' start tag on line 257 position 6 does not match the end tag of 'connectionManagement'. Line 258, position 3." inner exception. I double-checked my entire project and there is not a single reference to "connectionManagement" anywhere! I even tried to check AppDomain.CurrentDomain.SetupInformation.ConfigurationFile's value and it indicates the right config file.
By fixing this connectionManagement issue I'll probably be able to run my application, but do you guys have any idea about where this might be coming from?
Problem was on the machine.config file on the server. Changing it solved the problem!

Could not load type 'PrintMan.MvcApplication'

I am making my very first asp.net project live and running into what I assume is configuration options. Note that there are similiar threads on StackOverflow regarding this but I have already gone through those answers but no success.
The project is working perfectly in my dev environment but on the production server it fails to work. I have restarted IIS, I have currently only this site in the config and the namespace is correct.
Having limited experience in this I am hoping someone can explain what the underlying issue is :)
Server Error in '/' Application.
Parser Error
Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.
Parser Error Message: Could not load type 'PrintMan.MvcApplication'.
Source Error:
Line 1: <%# Application Codebehind="Global.asax.cs" Inherits="PrintMan.MvcApplication" Language="C#" %>
Source File: /global.asax Line: 1
Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.34274

Error during deployment on server

Project runs fine on my local machine, but when I deploy on server I get this problem regarding active report, any help will be appreciated.
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a
configuration file required to service this request. Please review the
specific error details below and modify your configuration file
appropriately.
Parser Error Message: Could not load file or assembly
'ActiveReports.PdfExport, Version=6.1.2814.0, Culture=neutral,
PublicKeyToken=cc4967777c49a3ff' or one of its dependencies. The
system cannot find the file specified.
Source Error:
Line 52: Line 53:
--> Line 54:
Line 55:
Line 56:
It seems that either ActiveReports.PdfExport dll is missing from the server or it is of a different version. Please make sure the version is the same and that its CopyLocal property is set to true and is copied to the deployment server.

Culture is not supported

I'm using Visual Studio 2012 Ultimate version.
I've got this error and I don't know how to solve it.
Culture is not supported.
Parameter name: name
en-UK is an invalid culture identifier.
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.Globalization.CultureNotFoundException:
Culture is not supported. Parameter name: name en-UK is an invalid
culture identifier.
please help me
Go to Debug -> Options -> Debugging and tick "Enable Just My Code"
You should try en-GB for English (United Kingdom)
List of Cultures
In my case with IIS Express, it was caused by its inability to write to C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files as IIS Express runs by a current user. So I've added permission to write to it for the current user to solve the error.

Can't run uploadify for asp.net

I have downloaded the example code/demo from:
http://www.technowise.in/2009/12/uploadify-aspnet-c-vb-examples-demo.html
and when I try to run any of the aspx files, I just get the following message from the server:
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.
Source Error:
Line 46: ASP.NET to identify an incoming user.
Line 47: -->
Line 48: <authentication mode="Windows"/>
Line 49: <!--
Line 50: The <customErrors> section enables configuration
Source File: C:\Inetpub\wwwroot\test_uploader\uploadify\web.config Line: 48
Version Information: Microsoft .NET Framework Version:2.0.50727.3623; ASP.NET Version:2.0.50727.3618
Anyone know why this is happening? I can normally run asp.net 2.0 and above web-forms perfectly will on this server.
You get this error because you have place a web.config in a subdirectory and this contains sessions that should be there, except if you define a new application/pool asp.net in this subdirectory of your iis.
From you question, here is the path of your web.config, but this must be one directory up, or not exist at all, or remove the lines that can not be there.
C:\Inetpub\wwwroot\test_uploader\uploadify\web.config

Categories

Resources