473,698 Members | 2,304 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Desktop Application Culture Setting

hi guys!
i've got one interesting problem.

one of my utility is generating data machine specific, i mean the data
is generated in the culture that the machine has.
my problem is with the numerical data, especially with double values.
the numeric data fetched from the database and saved on the machine is
in non english culture.
i want data in only english culture but i dont know how to set it.

The application is Windows Desktop Application.

can anyone tell me how can i set culture for my application so that it
can always you english culture(US or UK) for Datetime and numeric data?

Tools
c#.net 2005 (VS.NET 2.0)
ms sql server 2000

thanks,
Lucky

Aug 16 '06 #1
2 2295
Lucky,
can anyone tell me how can i set culture for my application so that it
can always you English culture(US or UK) for Datetime and numeric data?
This is a little bit difficult.

There is an US culture for English and there are the cultures for other
countries including the UK where English is spoken.

They both use the dot as decimal separator, but have an other date notation,

The InvariantCultur e is special made for that, but that you cannot set as
culture. You can only use it in the datetimeparse and probably some other
classes.

Does not give much help, but if you want to make your program Country
depended (the US culture is not used in Canada by instance) than you have to
choice for one.

Thread.CurrentT hread.CurrentCu lture = New CultureInfo("en-US")
Thread.CurrentT hread.CurrentUI Culture = New CultureInfo("en-US")

I hope this helps anyway

Cor
can anyone tell me how can i set culture for my application so that it
can always you english culture(US or UK) for Datetime and numeric data?

Tools
c#.net 2005 (VS.NET 2.0)
ms sql server 2000

thanks,
Lucky

Aug 16 '06 #2
Hi Cor,
I do understand that making an application Culture specific is not a
good idea but requirement is in such a way that i have to standerdize
some of the part in specific manner so that when the data comes for
processing application finds it required formate.

by the way, that was great help for me. i was just looking for that
exact line of code.

thanks,
Lucky

Cor Ligthert [MVP] wrote:
Lucky,
can anyone tell me how can i set culture for my application so that it
can always you English culture(US or UK) for Datetime and numeric data?
This is a little bit difficult.

There is an US culture for English and there are the cultures for other
countries including the UK where English is spoken.

They both use the dot as decimal separator, but have an other date notation,

The InvariantCultur e is special made for that, but that you cannot set as
culture. You can only use it in the datetimeparse and probably some other
classes.

Does not give much help, but if you want to make your program Country
depended (the US culture is not used in Canada by instance) than you have to
choice for one.

Thread.CurrentT hread.CurrentCu lture = New CultureInfo("en-US")
Thread.CurrentT hread.CurrentUI Culture = New CultureInfo("en-US")

I hope this helps anyway

Cor
can anyone tell me how can i set culture for my application so that it
can always you english culture(US or UK) for Datetime and numeric data?

Tools
c#.net 2005 (VS.NET 2.0)
ms sql server 2000

thanks,
Lucky
Aug 17 '06 #3

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

Similar topics

10
572
by: mail2deepa | last post by:
Hello, I want to know the difference between desktop application and intranet application. when to do desktop application and when intranet application. deepa
8
4714
by: Uttam | last post by:
Hello, I am currently in the process of developing an application in a pure desktop world using Access 2000. I am intending to convert this pure desktop application into a Client Server application with Access 2000 as the front end and the each of the following as the backend: 1) Oracle
4
3731
by: Elhanan | last post by:
hi.. all a client of ours is considering to move from a dos application to windows desktop application. the application is for traveling agency, the database is rather large. their current database for other application is SQL-SERVER. they have 12 users.
0
1143
by: Lucky | last post by:
hi guys! i've got one interesting problem. one of my utility is generating data machine specific, i mean the data is generated in the culture that the machine has. my problem is with the numerical data, especially with double values. the numeric data fetched from the database and saved on the machine is in non english culture. i want data in only english culture but i dont know how to set it.
3
2293
by: ebbflow | last post by:
I've seen explainations on how to impersonate a non aspnet user when a web page is called within an web application, but I have a different impersonation issue. I have a windows desktop application (not a web app) that is used by our web administrator to control some of the web application's settings. It also has some troubleshooting features. One feature that I'd like is to verify that the aspnet user has some permissions to open some...
0
2296
by: kidders | last post by:
Seem to be having problems with the en-GB culture/uiCulture setting, its making dates a format of the incorrect MM/dd/yyyy. I've searched the groups on this issue, here is a lengthy thread, where i have tried every thing stated: *registry settings *regional language settings *page level and app level culture/uiCulture settings...
2
1569
by: =?Utf-8?B?UGV0ZXI=?= | last post by:
I wonder whether this article http://msdn2.microsoft.com/en-us/library/ms973831.aspx is still applicable to ..net 2.0/.net 3.0 and the current computing environment. Also, does it happen that an application may be both Web and Desktop application?
1
1813
by: Bartholomew Simpson | last post by:
I wrote a desktop application in C++ a little while ago, and I will like to port it to a web application. Here are the details: 1). ALL business logic is held in ANSI C++ libraries (e.g. I make extensive use of the BOOST C++ libraries) 2). The front end is written entirely in VB6 What I want to do is to is to be able to be able to have a choice of
2
7032
by: sezanawa | last post by:
Hi Guys, I am new to java deployment things. Specially for desktop applications. I used to work with J2EE and i did deployment only for web projects. Now i have developed a small desktop application. Its based on java swing. My application gonna serve on windows and linux systems. Now i want to deploy my application along with all libraries etc. Simply i dont know how to do that. I googled for such a thing but no success. Can i pack my...
4
1200
by: BiffMaGriff | last post by:
Hello, I am developing a destop application for a client that has a "tricked out" version of windows. Essentially they customised every single part of windows that they could. Unfortunatly they insisted on having me develop my application as a desktop application and it has become a nightmare of discovering inconsistency after inconsistency where I have to manually set some setting to the default so that my application can run as if it was on...
0
8674
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
8603
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9027
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8895
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
8861
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7725
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...
0
4369
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...
0
4619
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3046
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

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.