473,670 Members | 2,405 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

problems with culture / .net installation en-GB

We recently installed the 1.1 redist of .Net on a new server. Only
after installing .Net did I realize that the regional settings of the
server had not been localized.

The application we have written uses GB style dates i.e. dd/mm/yyyy.
When running new server we were getting error message - i.e. incorrect
date format. First we removed the app and .net, reset the locale,
rebooted and re-installed everything. However server still defaulting
to US dates. So we have now edited web.config and set culture="GB-en"
uiculture="GB-en". The app is now no longer complaining about the date
format, but it is still using US default days - i.e Sunday=7 rather
than sunday=1. This does not seem to be impacted by changing the
culture in web.config.

I have two questions. (1) why does .Net continue to believe that it
should use US format even though the regional settings on the server
have been changed - I have reset looked through the registry but could
not identify a problem key. The machine.config shows culture=neutral
for all entries.

(2) Where do the US day numbers comefrom. Is there some way of setting
these in web.config.

Many thanks for help.
Davud
Nov 18 '05 #1
4 4219
What exactly is the expression that returns 7 ?

In particular note of course that enums for the days of the week won't
change. What change is the property that defines the first day of the week.
Try :
System.Threadin g.Thread.Curren tThread.Current Culture = New
System.Globaliz ation.CultureIn fo("en-US")

Response.Write( System.Threadin g.Thread.Curren tThread.Current Culture.DateTim e
Format.FirstDay OfWeek)

System.Threadin g.Thread.Curren tThread.Current Culture = New
System.Globaliz ation.CultureIn fo("en-GB")

Response.Write( System.Threadin g.Thread.Curren tThread.Current Culture.DateTim e
Format.FirstDay OfWeek)


Patrice

--

"David Mc" <da*********@ac xiom.com> a écrit dans le message de
news:55******** *************** ***@posting.goo gle.com...
We recently installed the 1.1 redist of .Net on a new server. Only
after installing .Net did I realize that the regional settings of the
server had not been localized.

The application we have written uses GB style dates i.e. dd/mm/yyyy.
When running new server we were getting error message - i.e. incorrect
date format. First we removed the app and .net, reset the locale,
rebooted and re-installed everything. However server still defaulting
to US dates. So we have now edited web.config and set culture="GB-en"
uiculture="GB-en". The app is now no longer complaining about the date
format, but it is still using US default days - i.e Sunday=7 rather
than sunday=1. This does not seem to be impacted by changing the
culture in web.config.

I have two questions. (1) why does .Net continue to believe that it
should use US format even though the regional settings on the server
have been changed - I have reset looked through the registry but could
not identify a problem key. The machine.config shows culture=neutral
for all entries.

(2) Where do the US day numbers comefrom. Is there some way of setting
these in web.config.

Many thanks for help.
Davud

Nov 18 '05 #2

Hi Patrice,
The code you supplied returns Sunday/Monday in that order which is
strange as it implies that the first day of the week for the en-US is
Sunday and For en-GB Monday. I am asking the developers for access to
the source code. So that I can see what is going on. Many thanks for
replying to my mail. I will post again when I have the source.

Dave
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 18 '05 #3
Do you mean it shouldn't . AFAIK the fisrt day of the week is Monday in US.
Not sure for GB.

The 7 sounds really strange to me as the days enumeration for .NET renges
aFAIK from 0 (Sunday) to 6

Patrice

--

"David McKee" <da*********@ac xiom.com> a écrit dans le message de
news:eW******** *****@TK2MSFTNG P10.phx.gbl...

Hi Patrice,
The code you supplied returns Sunday/Monday in that order which is
strange as it implies that the first day of the week for the en-US is
Sunday and For en-GB Monday. I am asking the developers for access to
the source code. So that I can see what is going on. Many thanks for
replying to my mail. I will post again when I have the source.

Dave
*** Sent via Devdex http://www.devdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 18 '05 #4
Patrice,

Problem now resolved, many thanks for your help. I did pull up and
plough through the code - it was a little hard to follow - but that
was not the issue. The problem was that when the Oracle client
software was installed it took it NLS_LANG from the system locale of
the NT server. Thus when aspnet made a connection to Oracle it was
explicitly setting NLS_LANG etc for its session. Changing the
registry entry in HKLM.Software.o racle.home0 from american to uk
english sorted it out.

Thanks Again.
Dave
Nov 18 '05 #5

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

Similar topics

1
8664
by: black hawk | last post by:
Hello, i have a big problems, to install oracle 9i v9.2 Server to my "Windows XP" with Service Pack 2 and all security and other updates from Microsoft. The "Universall Installer" (Standard Edition is Selected and only Software is Selected) throws an exception, during the installation by 11 Percent installation progress!
0
3462
by: black hawk | last post by:
Hello, i have a big problems, to install oracle 9i v9.2 Server to my "Windows XP" with Service Pack 2 and all security and other updates from Microsoft. The "Universall Installer" (Standard Edition is Selected and only Software is Selected) throws an exception, during the installation by 11 Percent installation progress!
0
2630
by: pcgxk | last post by:
Due to some bugs in .NET SP1 which we are currently review with MS under separate cover, I am having to regress the patching levels of several of my desktops to rebuild and retest several versions of our code. To do this I had been previously advised to ensure that both versions of the Framework (the software supports both 1.0 and 1.1) were completely removed from the PC before starting the installs again from scratch. i.e. to do this as...
2
6259
by: mb12036 | last post by:
All- Having a problem installing a DB2 client on a machine running AIX version 5.0. Client appeared to install one time succesfully, then was uninstalled and a reinstall was attempted. For some reasons, it does not complete the reinstall. See the status report from the GUI installer at the end of this note. Errors are towards the bottom. Everything installed in /usr/opt for DB2 but the sqllib folder that is supposed to be created in...
3
3645
by: Shapper | last post by:
Hello, I am working on a multi-language web site. After a lot of searching and reading I was able to define a way to do this. However, I need some help to put this on. I am working on ASP.Net/VB. I have a few problems which I hope somebody can help me with: 1. How to set the en-US as the default culture of my entire web site?
2
1523
by: fabrice | last post by:
hello, I nedd help to create and use Library Satellite. I'm using Web Form under framework 1.1 and VB.NET I'm not using Visual Studio. I'd like to internationalize my web application with using .DLL For the moment i test many solutions with one .aspx page to create a model. But i'm not.
9
3915
by: Edge | last post by:
hi, I am saving the user selected culture in a session variable so I can apply it back to all pages when refreshed and then load the proper .resx values. For that I am using global.asax
2
3009
by: Jesus | last post by:
Hi! I'm migrating a web application (ASP.NET) from Framework 1.1 to Framework 2.0. I have a problem with that, and I didn't found a solution changing something in web.config or something like that. The problem is that when using Framework 1.1, the function toShortDateString, returns a string with a date at machine culture (in
3
3377
by: shapper | last post by:
Hello, I am working on a multilanguage Asp.Net 2.0 web site. I need to do the following: 1. Set a default culture in Web.Config File. 2. Create a function which changes culture when pressed. Remember the choosen culture next time the visitor comes to the web site. 3. Retrieve the current culture.
1
1948
by: Cindy Lee | last post by:
My browser always shows the en-US local resource file, even though I try to set it to my french resource file: (this is the first part of onPageload--) Thread.CurrentThread.CurrentCulture = new CultureInfo("fr-FR"); Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture; That code doesn't seem to work on my web app. I want to be able to change the local resource file based on an argument
0
8466
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8901
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
8591
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7412
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6212
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5683
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4208
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
2037
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1791
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.