Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
How can we use Culture Auto in project
How can we use Culture Auto in project?
✍: Guest
We will make a simple login screen which we will try to use for English as well as Greek.
The login screen will display English settings when an English user logs in and Greek
Settings when a Greek user logs in. So below are the steps to start with.
In the above figure you can see the login page. You can find the same in CD as named
gLoginScreen.aspxh. Itfs a simple page with two labels and two text boxes. Now the labels
values i.e. gUser IDh and gPasswordh should be changed according to regional settings
set on the browser. So below are the steps for the same:
ã Make two resource files as shown below one for Greece and other for English.
There are three values defined for gUseridh, gPasswordh and the main title of the
page. One important thing to note is the naming convention of the files. You need
to tag the naming convention with the language code. You can see from the below
figure the resource files naming convention is divided in two three parts File name,
Language code and resource file extension. In this sample we will demonstrate for
English and Greek language so I tagged the file with gelh language code.
Once you have defined your resource files we need to define two attributes
gUICulture=Autoh and gCulture=Autoh. See the above figure gCulture Auto in
Actionh.
Final step you also need to define resource key at the UI object level. You can see a
sample of the same in figure gCulture Auto in Actionh.
Compile the project, run and see the output after changing regional settings for both
languages. You should see different outputs as shown in the above figure. With out a
single line of code everything works…. That’s the magic of “UICulture=Auto” attribute.
2007-11-01, 5355👍, 0💬
Popular Posts:
What Are Data Pump Export and Import Modes? - Oracle DBA FAQ - Loading and Exporting Data Data pump ...
Write down the equivalent pointer expression for referring the same element a[i][j][k][l]? a[i] == *...
What’ is the sequence in which ASP.NET events are processed ? Following is the sequence in which the...
If we inherit a class do the private variables also get inherited ? Yes, the variables are inherited...
If we have the following in a Java code: String s="abc"; String s2="abc"; Then what will be output o...