alexxx
Advanced Member level 4
Hi!
I would like to create a multilanguage project in C#. I created a test project for that, with a simple form that contains just one button. I want the button to have an english text on it when english language is selected, and a greek text when greek language is selected. After I changed the "Localizable" property to true, I selected the two languages and two resource files were created, one for each language.
What I accomplished so far, is to change the language before initialization:
What I want to do is change the language during runtime, when button is pressed:
Any suggestions?
Thanks!
I would like to create a multilanguage project in C#. I created a test project for that, with a simple form that contains just one button. I want the button to have an english text on it when english language is selected, and a greek text when greek language is selected. After I changed the "Localizable" property to true, I selected the two languages and two resource files were created, one for each language.
What I accomplished so far, is to change the language before initialization:
Code:
public Form1()
{
Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("en-US");
//Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("el-GR");
InitializeComponent();
}
What I want to do is change the language during runtime, when button is pressed:
Code:
private void button1_Click(object sender, EventArgs e)
{
//Code for language change should be placed here
}
Any suggestions?
Thanks!