Use of culture auto, DOT NET Programming

Assignment Help:

How can we use Culture Auto in project?

We will make a very simple login screen which we will try to use for English as well as the Greek.

The login screen will display English settings when an English user logs in and the Greek Settings when a Greek user logs in. So below are the some steps to start with.

883_Culture auto.png

Figure: - Culture Auto in action

In the figure above you can view the login page  i.e. the "LoginScreen.aspx". It is a simple page with 2 labels and 2 text boxes. The labels values i.e. the "User ID" and "Password" should be changed according to the regional settings set on the browser. So below are some of the steps for the same:-

1) Make 2 resource files as shown below one for Greece and other for the English. There are 3 values defined for "Userid", "Password" and the main title of the page. The One important thing to note is the naming convention of the files. You require tagging the naming convention with the language code. You can see from the figure below that the resource files naming convention is divided into 3 parts viz. Language code; File name & resource file extension. In the sample we will explain for the English & Greek language so I tagged the file with the "el" language code.

2360_Culture auto1.png

Figure: - Resource file naming conventions

Below are the 2 resource files defined :

401_Culture auto2.png

Figure: - Greek and English resource files

2) Once you have defined your resource files we require to define two attributes "UICulture=Auto" & "Culture=Auto". See the figure above "Culture Auto in Action".

3) The Final step you also require to define the resource key at the UI object level. You can see a sample of the similar in the figure "Culture Auto in Action".

1048_Culture auto3.png

Figure: - Login screen according to settings

Compile the project, run and see the output after changing the regional settings for both the languages. You must see different outputs as shown in the figure above. Without a single line of code everything works.... That is the magic of the "UICulture=Auto" attribute.


Related Discussions:- Use of culture auto

Scavenging, What is scavenging? When server running your ASP.NET applic...

What is scavenging? When server running your ASP.NET application runs low on the memory resources, items are discarded from the cache depending on cache item priority. The Cach

Converting rs. to paisa - c# program, Converting Rs. to Paisa - C# Program ...

Converting Rs. to Paisa - C# Program Need the code of C# Program for Converting Rs. to Paisa.

How do i force the dispose method to be called automatically, How do I forc...

How do I force the Dispose method to be called automatically, as clients can forget to call Dispose method? To Call the Dispose method in the Finalize method and in the Dispose

Use a checkbox in a datagrid, How to use a checkbox in a datagrid? The ...

How to use a checkbox in a datagrid? The steps to be done are as follows:- 1)    In the ASPX page you have to add Itemtemplate tag in datagrid. 2) I

Bug correction and prediction, Bug Correction and Prediction Project Des...

Bug Correction and Prediction Project Description: The project is about the prediction of bugs and resolves the bug in the sample program using costriage algorithm. You have

Yuy, Ask queyuyuystion #Minimum 100 words accepted#

Ask queyuyuystion #Minimum 100 words accepted#

What is strong-typing versus weak-typing, What is strong-typing versus weak...

What is strong-typing versus weak-typing? Which is preferred? Why? Strong type is checking the types of variables as soon as possible, usually at compile time. While weak typing

Explain the postback process as use with web forms, Question: (a) Expla...

Question: (a) Explain the Postback process as use with Web Forms. (b) Write extract codes to demonstrate how to store and retrieve values in: (i) a Session Object (ii)

Auto stock market robot, Auto stock market robot Project Description: ...

Auto stock market robot Project Description: A total solution for the Robot trading on Nse , currency, Mcx, ncdex,using formulas or using buy sell signals . The solution s

Samba pos development customisation english version, Project Description: ...

Project Description: customise samba pos. Just remove samba pos logo and rebrand it. The title in the frame needs to be changed as well as the splash screen at the beginning.

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd