Total Pageviews

8/29/2014

Localization with ASP.NET MVC Model Metadata

ASP.NET MVC has default facility for DATA ANNOTATION to provide validation. If you want to set your validation message as localization means when culture change, your validation message text change as per culture. You can also change label text with the change of culture. Let’s see step by step.

Here, we set two culture conversion ENGLISH and GERMAN
1.    Add Resource.resx (For English ) and Resource.de.resx (For German)
--> Project properties Folder and AddNewItem Add Resource.resx (For English)
 --> Same as Add Resource.de.resx (For German)
















--> Make sure to change the Access Modifier to Public (default is Internal)

2.    Install-Package ModelMetadataExtensions

3.    In model file sets error message and label

























-->ErrorMessageResourceType sets type created by build provider. I added WebApplication.Properties.
-->ErrorMessageResourceName sets from resource file     
-->For display label sets label name from resource file.  
4.    Sets Global.asax file for URL routing.

5.    Sets controller like
 6.    When runs with English culture
7.    When runs with German culture














Happy programing friends. 

51 comments:

Regina Rj said...

This information was o helpful.
Web designing training in chennai

raphael said...

Wow excellent article. This will be more benefit for the asp.net beginners. and please keep update like this information.

digital marketing training Chennai

kathickanitha55 said...

I read this articles really awesome.You provided another one great article.The programming was very easily understand and more important coding are provided on this post and this is very valuable in my studies.
iOS Training in Chennai

Aamala Ahona said...

Hai,

Nicely written post. I am just about to start a new blog and there could not have been a better guide than this one for some good pointers. I am looking forward to starting a successful blog after reading this incredibly useful post of yours. Waiting for more such posts like this.

Keep writing and sharing!

aamala

SEO Training in Chennai

henris said...

Really nice and i got some valid information. Thank you for that and please keep update like this information.

Web Designing Training in Chennai

kanmani karthick said...

All of these tips are great, that’s very interesting.Thanks for sharing that valuable information.


Oracle SQL Training in Chennai

henris said...

Wow amazing i saw the article with execution models you had posted. It was such informative. Really its a wonderful article. Thank you for sharing and please keep update like this type of article because i want to learn more relevant to this topic.


SQL DBA Training in Chennai

Maani kamili said...

It is really a great and useful piece of info. I’m glad that you shared this helpful info with us. Please keep us informed like this. Thank you for sharing.

Digital marketing company in Chennai

Rajapriya R said...

nice and really helpful article to everyone... thanks for sharing

selenium training in chennai | selenium training institute in chennai | Android training in chennai | android training institute in chennai

mythily mythu said...

Really nice and i got some valid information.
J2EE training in chennai

http://essay-writing.company/ said...

My husband is a programer and he will explaint to me the things that I don't understand.

custom writing said...

This is an incredible article that allows you to learn more about programming Share it with my husband, he is going to be very useful in his work.

introduction chapter said...

Very nice and detailed written this post. I behold a very clear, even taking into account the fact that I do not have extensive knowledge in this subject.

for IT the said...

I have read your blog its very attractive and impressive. I like it your blog.

ASP.NET MVC Training in Chennai | ASP.NET MVC Training in Chennai

ASP.NET MVC Online Training | Online LINQ Training | ASP.NET Online Training

sivanesan said...

Nice post. Very interesting to read. Thank you for Sharing.
erp in chennai

Brave Technologies said...

Thank you for this valuable information. Get your business to the next level in simple steps. We provides lowest price of erp Software for our clients erp solution providers in Chennai

sunitha vishnu said...

It is amazing and wonderful to visit your site.Thanks for sharing this information,this is useful to me...
Android Training in Chennai
Ios Training in Chennai

ASO Services said...

Thanks a lot for sharing this with all of us, I like it and we can communicate. Do you need buy app ratings and reviews. To boost app ranking and double app downloads now.

Simmi Sharma said...

very interesting and most amazing post and giving details to be help me thanks
Candid photographers in jaipur

Sasha said...

Escort service in jaipur

good knowledge for your post thanks

vishnu said...

Thank you for sharing this information

DOT NET Course in Chennai | DOT NET Training in Chennai

Avi said...

Great article, really very helpful content you made. Thank you, keep sharing.

Digital Transformation Services | Austere Technologies

Avi said...

This blog is helpful, keep sharing. Thank you.

cloud Services | Austere Technologies

sample said...

Very good informative article. Thanks for sharing such nice article, keep on up dating such good articles.


Best Software Company | Austere Technologies

dev said...

wow...nice blog, very helpful information. Thanks for sharing.

IOT SERVICES | INTERNET OF THINGS | Austere Technologies

ram chinna said...

Really great blog, it's very helpful and has great knowledgeable information. Thanks for sharing.

Software Security Services | Austere Technologies

ram said...

VERY INFORMATIVE BLOG. KEEP SHARING SUCH A GOOD ARTICLES.

Mobility Services | Austere Technologies

desh said...

This is really great informative blog. Keep sharing.

Best Quality Managment Services | Austere Technologies

preethi Shetty said...

Looking really great article with useful content, thanks much for creating sharing here please do keep on sharing...
Best Online Software Training Institute | Asp.Net MVC Training

avinash said...

Wow...What an excellent informative blog, really helpful. Thank you.

Best Commerce College| Avinash college of commerce

Kamal said...

Good enlightening article. A debt of gratitude is in order for sharing such pleasant article, keep on up dating such great articles.
Education | Article Submission sites | MBA Guide | Technology

avinash said...

Very good informative article. Thanks for sharing such nice article, keep on up dating such good articles.

Best Commerce College in Hyderabad | Avinash College of Commerce

Steve M said...

This has much useful and interesting guidance for freshers who are looking to upgrade the skills with Dot Net. Thank you.

Dot Net Training in Chennai
Dot Net Course in Chennai

ajay. chinna said...

Nice post keep do posting The Info was too good, for more information regarding the technology Click
Amazon web Services Training
and more information
Devops training
Salesforce certification Training program

Avinash said...

VERY INFORMATIVE BLOG. THANK YOU.

Best junior college in Hyderabad | Avinash College of commerce

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Block Chain Services

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best System Integration Services

sandy said...

Thank you for sharing this valuable information. But get out this busy life and find some peace with a beautiful trip. book Andaman holiday packages

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Finance Training in Hyderabad

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best company secretary course

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Chartered Accountancy

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Chartered Accountancy

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Cost And Management Accountancy (CMA)

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Certified Public Accountant

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Certified Financial Analyst

sandy said...

Thank you for sharing this valuable information. But get out this busy life and find some peace with a beautiful trip. book ANDAMAN TOUR PACKAGE @24599

sandy said...

Thank you for sharing this valuable information. But get out this busy life and find some peace with a beautiful trip. book BEST ANDAMAN HONEYMOON PACKAGE @5999

Avinash College Of Commerce said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Association Of Chartered Certified Accountants

Avinash College Of Commerce said...

Hi Thanks for the nice information its very useful to read your blog. We provide Software Development Services

Avinash College Of Commerce said...

Hi Thanks for the nice information its very useful to read your blog. We provide best Chartered Institute Of Management Accountants

sandy said...

Hi Thanks for the nice information its very useful to read your blog. We provide Software Development Services

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Affiliate Network Reviews