Use multilingual in C # desktop applications

xiaoxiao2021-03-06  60

Recently, I have been doing Windows desktop applications, I didn't touch ASP.NET. In WIN FORM, we can also make software multi-language, which is the same as ASP.NET. The following is an example of a Windows desktop application:

Note: 1. You can set language resource files for each form, or you can put the language to a separate resource file. Lang.en-cn.resx in the example, Lang.en.resx is an instance saved to a single file, where some public software languages ​​can be stored; while the mainform.resx and mainform.en.resx can be used Please note that the control is declared as an Internal type. 2, save the configuration to the path to the registry, if you don't have to register, you can save it to an XML configuration document. This example is the registry to save the settings. 3. Access the regional resources of this form, you need to set the localizable property to TURE, ie in the form generator code: system.resources.resourceManager resources = new system.resources.ResourceManager (Typeof);

Download address: Click here to download source code

转载请注明原文地址:https://www.9cbs.com/read-84299.html

New Post(0)