Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / June 2006

Tip: Looking for answers? Try searching our database.

How to get DateTime format settings from Control Panel

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Egil Winther - 23 Jun 2006 08:45 GMT
Hi everyone,

I'm having difficulties retrieving datetime formats that has been customized
in the control pane.

I can get the cultureinfo, but I get same settings regardless of what i do
in the control panel.

Any ideas?

Brgds
Egil Winther
¨ShipNet AS
Markus Kling - 23 Jun 2006 15:44 GMT
The CurrentUICulture defaults to the current user UI language settings but
does not reflect the individual settings. You must get and set them manually
from HKEY_CURRENT_USER\Control Panel\International and change the
CultureInfo object accordingly.

Markus

> Hi everyone,
>
[quoted text clipped - 9 lines]
> Egil Winther
> ¨ShipNet AS
Mihai N. - 24 Jun 2006 09:50 GMT
> The CurrentUICulture defaults to the current user UI language settings but
> does not reflect the individual settings. You must get and set them
> manually
> from HKEY_CURRENT_USER\Control Panel\International and change the
> CultureInfo object accordingly.
For formatting info you should use CurrentCulture, never CurrentUICulture.
CurrentUICulture is used for UI language settings (as you mentioned).

Signature

Mihai Nita [Microsoft MVP, Windows - SDK]
http://www.mihai-nita.net
------------------------------------------
Replace _year_ with _ to get the real email

Egil Winther - 26 Jun 2006 09:26 GMT
Thanks guys,

I have tried using the CurrentCulture, but it does not seem to change
whatever I do in the control panel.

I will try to use the registry setting and see what happens.

Brgds
Egil Winther
ShipNet AS

>> The CurrentUICulture defaults to the current user UI language settings
>> but
[quoted text clipped - 4 lines]
> For formatting info you should use CurrentCulture, never CurrentUICulture.
> CurrentUICulture is used for UI language settings (as you mentioned).

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.