ASP.NET MVC验证消息没有得到本地化 [英] ASP.NET MVC validation message does not get localized

查看:150
本文介绍了ASP.NET MVC验证消息没有得到本地化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用ASP.NET MVC 4显眼客户方的验证。在我的应用程序的语言为德语(在web.config文件中定义)

I am using ASP.NET MVC 4 with unobtrusive clientside validation. The language in my application is german (defined in the web.config file)

如果我有一个必填字段(与数据的注解在我的code头等配置),客户端验证工作正常。唯一的缺点:该消息未本地化

If i have a required field (configured with data-annotations in my Code First Classes), the client side validation works fine. the only downside: The Message is not Localized.

实地XXXX是必需的。

The Field XXXX is required.

有没有一个解决这个问题的?

Is there a solution out for this problem?

推荐答案

您必须安装.NET Framework语言包,可根据您的.NET Framework版本:

You must install the .NET Framework Language pack, according to your .NET Framework version:

Microsoft .NET框架4.5语言包:
<一href=\"http://www.microsoft.com/de-de/download/details.aspx?id=30667\">http://www.microsoft.com/de-de/download/details.aspx?id=30667

Microsoft .NET Framework 4.5 Language Pack: http://www.microsoft.com/de-de/download/details.aspx?id=30667

Microsoft .NET框架4全语言包:
<一href=\"http://www.microsoft.com/de-de/download/details.aspx?id=23067\">http://www.microsoft.com/de-de/download/details.aspx?id=23067

Microsoft .NET Framework 4 Full Language Pack: http://www.microsoft.com/de-de/download/details.aspx?id=23067

在这些网页上,检查要求,以了解他们是否符合你的需求(即:操作系统版本,x86或x64等)。如果他们没有满足您的需求,搜索谷歌像的Microsoft .NET Framework德语语言包。

In these pages, check the requirements, in order to see if they meets your needs (i.e.: Operating System Version, x86 or x64, etc.). If they don't meet your needs, search on Google something like "Microsoft .NET Framework German Language Pack".

这篇关于ASP.NET MVC验证消息没有得到本地化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆