1 Replies - 15145 Views - Last Post: 17 March 2011 - 04:41 AM

#1 SõftHảcker   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 13
  • Joined: 05-March 11

How to make Application Multilanguage?

Posted 16 March 2011 - 08:48 AM

I want to make a Windows Form Multilanguage. How to do that?????????????????????????
I have [Microsoft Visual C++ 2008 Express Edition] and some [RESX files].

I want to load another language by clicking a button, or on combobox item change, or on form load, etc...

Without the use of tons of code!!

private: System::Void Sample_Load(System::Object^  sender, System::EventArgs^  e) {
   // ????????
   // i want to change the language there!!!!!!!! using RESX files

here a button click, what I have to do, that the language changes.
to remember: i want to use RESX files for that.

i can not find something useful for me :snap: :death:

i found this on web


don't work, it's undeclared :sad3:
but it would be awesome, only one line of code to change the language of the application :santa:

a full example would be AWESOME!
of course in C++ not in C#

is there any help, a tutorial, example codes?????

This post has been edited by SõftHảcker: 16 March 2011 - 08:48 AM

Is This A Good Question/Topic? 0
  • +

Replies To: How to make Application Multilanguage?

#2 SõftHảcker   User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 13
  • Joined: 05-March 11

Re: How to make Application Multilanguage?

Posted 17 March 2011 - 04:41 AM

OKAY, i finally got it.

I know, how to create multilanguage apps.

i have this code
is there something better. because with this method i have to write thousand lines of code,
for every string one line :wheelchair:

// Initalize and Load the Language Resources from this Form.
				 ResourceManager^ resManager = gcnew ResourceManager("UnicodeTCHARCMD.Extendor", Assembly::GetExecutingAssembly());

				 // Set the Culture to the language we want apply.
				 CultureInfo^ ci = gcnew CultureInfo("en-US");

				 // Apply the Language to the Form.
				 cLOSEFORMToolStripMenuItem->Text = resManager->GetString("cLOSEFORMToolStripMenuItem.Text", ci);
				 eXITAPPToolStripMenuItem->Text = resManager->GetString("eXITAPPToolStripMenuItem.Text", ci);
				 eXTENDORToolStripMenuItem->Text = resManager->GetString("eXTENDORToolStripMenuItem.Text", ci);
				 eXTENDToolStripMenuItem->Text = resManager->GetString("eXTENDToolStripMenuItem.Text", ci);
				 eXTRACTASToolStripMenuItem->Text = resManager->GetString("eXTRACTASToolStripMenuItem.Text", ci);
				 eXTRACTToolStripMenuItem->Text = resManager->GetString("eXTRACTToolStripMenuItem.Text", ci);
				 fILEToolStripMenuItem->Text = resManager->GetString("fILEToolStripMenuItem.Text", ci);
				 lANGUAGEToolStripMenuItem->Text = resManager->GetString("lANGUAGEToolStripMenuItem.Text", ci);
				 oPENToolStripMenuItem->Text = resManager->GetString("oPENToolStripMenuItem.Text", ci);
				 OptionsToolStripMenuItem->Text = resManager->GetString("OptionsToolStripMenuItem.Text", ci);
				 pROGRAMToolStripMenuItem->Text = resManager->GetString("pROGRAMToolStripMenuItem.Text", ci);
				 rESETSETTINGSToolStripMenuItem->Text = resManager->GetString("rESETSETTINGSToolStripMenuItem.Text", ci);
				 sAVEASToolStripMenuItem->Text = resManager->GetString("sAVEASToolStripMenuItem.Text", ci);
				 sAVEToolStripMenuItem->Text = resManager->GetString("sAVEToolStripMenuItem.Text", ci);

				 // Adding the languages to a the menu strip combo box.
				 toolStripComboBox1->Items->Add(L"English (USA)");
				 toolStripComboBox1->Items->Add(L"Deutsch (Österreich)");
				 toolStripComboBox1->Items->Add(L"Espaņol (Espaņa)");
				 toolStripComboBox1->Items->Add(L"Русский (Руссия)");
				 toolStripComboBox1->SelectedIndex = 0;

as you can see here, for each string, a extra line of code, pls :helpsmilie: , or is there no other way to do that
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1