views:

84

answers:

2

Hey

I want to make multilingual buttons, like those of the messagebuttons. I have a form with a cancel-button, but I want to have a multilingual text. For example, in German it is named "Abbrechen, in French "Annuler" and in English "Cancel". Like for MessageBoxes, those buttons are also multilingual. Is it possible to find out the string of the "MessageBox-Cancel-Button" of the current Language of the machine?

Regards

Wonderwhy

A: 

Why don't you use Localization?

Khaled
I am not so advanced to C# so I don't know how to handle with it.The MessageboxButtons OK, Cancel or Retry are always named different on machines with different languages. And I want to know how I make a "Cancel"-Button with the same settings, so different names at different langauages. The string must be saved on the machines. so how do I find them "Cancel"-string? Can u give ma e code-example?
Wonderwhy
+1  A: 

MSDN link "Walkthrough: Localizing Windows Forms"

http://msdn.microsoft.com/en-us/library/y99d1cd3(VS.71).aspx

Erik Philips
Is there no easier method? The "Cancel"-String of the system must be saved on the computer, for example, for messageboxbuttons.I don't want to create a new ressourcefile or multiple forms, I only want the "Cancel"-string of the current language installed on the computer. Isn't this possible?
Wonderwhy
You don't create a resource for each form, you create one resource that maps each strings to languages. For example, your "Cancel" and "Ok" Messages boxes will use the same resource file. And since you have custom forms with customs labels, having your own resources means everything can be localized, not just whatever the system can localize.
Erik Philips
Thx for the advise.Now I must find the different "cancel"-strings foreach language :D
Wonderwhy