473,396 Members | 1,871 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

WPF: Change the culture when application runs.

Hi all,

I’m very very new in C#/WPF world, but this fascinates me more and more. Now
I must find a way how our future application will use the localization /
globalization. I did all the steps I found in MSDN to create this (UID,
LocBaml, satellite, etc.) and I it works perfect (a little bit complicated
but anyway it works). The application starts in the OS culture starts, also
if I put at the beginning this code:
public App()
{
Thread.CurrentThread.CurrentUICulture = new CultureInfo("de-DE");
//Thread.CurrentThread.CurrentUICulture = new
CultureInfo("en-US");
}
It works perfect.
Now I try (and I spent too much time for this issue) to change the culture
online, when the application runs. Something like:
private void CheckLanguage(object sender, RoutedEventArgs e)
{
Thread.CurrentThread.CurrentUICulture = new CultureInfo((german)
? "de-DE" : "en-US", true);
}
When the user clicks a button to change from german to English. I guess I’m
too naive to believe that, but I don’t know what should I write so to get my
current main window show all stuff in other language?
For any idea thank you in advance!

Best regards,
Emanuil
Nov 20 '07 #1
0 3210

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

Similar topics

1
by: karen.mcdonagh | last post by:
Hi, I have generated resource files for a different language and generated a satellite assembly for it, signed it and placed it in the GAC. When I change the UI culture within the code the...
4
by: Shapper | last post by:
Hello, I have this image in my HTML code: <img src="images/en-US/myImage.jpg" /> I want to change the URL using the value of a Session variable. <img src="images/ Session("culture") Value...
1
by: brett | last post by:
Using MS Expressions Interactive, if I design a site that uses WPF functionality, (I have .NET 3.0 on my developer machine) how does it work once uploaded onto an ASP.NET 2.0 server that doesn't...
4
by: timor.super | last post by:
Hi group, I have a strange error. I'm a beginner with dotnet 3.0, when i try to run an wpf application from my windows explorer, the application crash. For example, i've downloaded the demo...
0
by: SapAddonDeveloper | last post by:
Hello, I am writing an add-on using vbnet/c# that runs inside a Sap B1 application. I need to be able to change the input language (little blue white icon on the system tray) on certain...
11
by: Don | last post by:
I have a WPF application in VB in VSTS 2008 RTM. I am trying to "blink" (momentarily clear) a field of data if the data is reloaded from the database to give the user some visual indication of the...
5
by: Carl Ganz | last post by:
I have a client that is looking at converting a massive WinForms .NET application to a server-based application in the next few years. The topic of ASP.NET came up and I have some doubts about...
23
by: raylopez99 | last post by:
Here I am learning WinForms and two months into it I learn there's a WPF API that is coming out. Is this WPF out yet, and is it a threat to WinForms, in the sense that all the library routines I...
5
by: PvdG42 | last post by:
Probably a simple beginner question, but... In VS 2008, C# WPF Windows Project: how to find the event list associated with a given control that has been placed on the form? I note that the...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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,...
0
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...
0
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...
0
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,...

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.