当应用程序进行全局化和本地化时,我们需要在代码中更改哪些区域?
例如
做
string datenew = Convert.ToDateTime("10/31/2012", CultureInfo.InvariantCulture)
.ToString();
不要
string datenew = Convert.ToDateTime("10/31/2012").ToString();
最佳答案
查看此链接,它会给您基本的了解: Internationalization tips for developers – I18N checklist
- 外部化所有可翻译内容 - 将文本从代码中取出并放入资源文件中
- 允许输入国际数据和外国文字
- 使用 Unicode 进行所有字符串处理
- 使用系统函数进行日期/时间和数字格式设置
- 使用系统函数进行排序和字符串比较
另外,检查这个 - SDLC Checklist for Globalized ASP.NET Web Applications
关于c# - 当应用程序进行全局化和本地化时,我必须做和不应该做的事情是什么?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13271611/