Redian新闻
>
问个多语言的Windows Application问题
avatar
问个多语言的Windows Application问题# DotNet - 窗口里的风景
z*n
1
我现在要做个软件,需要支持几种不同语言的用户界面,比如
英语,德语,汉语,日语等.请问一般是如何实现的?是不是把
所有界面上的文字都对应存在一个文件里然后根据语言
设置来读取相应字符并显示?各语言的长短不同,那么象各
BUTTON,LABLE等的SIZE如何控制?(除了一个个手工调)
我主要用VB2005
多谢
avatar
c*e
2
oops, sorry for the c# syntax. here's the VB version:
Public Sub New()
System.Threading.Thread.CurrentThread.CurrentUICulture = New System.
Globalization.CultureInfo("zh-CN")
' This call is required by the Windows Form Designer.
InitializeComponent()
' Add any initialization after the InitializeComponent() call.
End Sub

interface
then
file
avatar
c*e
3
if you just want to show strings in different languages on the user interface
(not including date time format, currency, string comparison/sort, etc), then
it's not too difficult a thing to do. what you need to do is:
1. design your form in the default language with the forms designer
2. change the language on the form (by setting Localizable and Language
properties on the form) and change strings on the UI to use the now
current
language to generate resources (which you can find as depe

【在 z*****n 的大作中提到】
: 我现在要做个软件,需要支持几种不同语言的用户界面,比如
: 英语,德语,汉语,日语等.请问一般是如何实现的?是不是把
: 所有界面上的文字都对应存在一个文件里然后根据语言
: 设置来读取相应字符并显示?各语言的长短不同,那么象各
: BUTTON,LABLE等的SIZE如何控制?(除了一个个手工调)
: 我主要用VB2005
: 多谢

avatar
z*n
4
Thanks to Cute for answering my original question, and now
more questions on vb.net MUI windows apps:
1. how do you change the button texts from message boxes?
e.g. showing 确定 instead of OK
2. being new to this whole .net and actually OOP thing, I guess
you need to make the msi file to include localized files, in
my case, one dll files for each language. Can I modify these
dll's afterwards? say my customer in Germany found an error
in my translation and want to change it, can he j
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。