Solved

Localization in Visual studio 2.0

Posted on 2006-06-13
4
717 Views
Last Modified: 2008-01-09
Environment : Visual studio 2005 C#
Topic : Localization, Resource Files

Question:
I have created a web site and added a page "Sample.aspx" which has 4 labels.
I want to change the text of the labels according to the specific Locale at runtime.

Using
.resx files stored in "App_LocalResources"

and

Thread.CurrentThread.CurrentUICulture = new CultureInfo("ar-ae");
Thread.CurrentThread.CurrentCulture = CultureInfo.CreateSpecificCulture("ar-ae");

the code works fine.

Now I want to put this .resx files in different folders instead of "App_LocalResources"
for e.g. "sample.aspx.en-gb.resx" in "EN" folder
"sample.aspx.ar-ae.resx" in "AR" folder

Also the .resx files should be editable after deployment.

Can anybody help me doing this functionality

0
Comment
Question by:ap_sajith
  • 2
4 Comments
 
LVL 14

Expert Comment

by:existenz2
ID: 16900805
Have a look at: http://aspalliance.com/726

This answers all your questions and gives you a nice and tidy solution.
0
 
LVL 14

Accepted Solution

by:
existenz2 earned 500 total points
ID: 16900810
Sorry wrong url. I meant:
http://www.ondotnet.com/pub/a/dotnet/2005/08/08/localizingaspnet20.html
http://aspalliance.com/426

You can create special resource assemblies. This allows you to edit the files after deployment without have to build the whole solution again.
0
 
LVL 21

Author Comment

by:ap_sajith
ID: 17067746
Apologies... Missed out on closing off the Q.

Cheers!
0

Featured Post

Is Your AD Toolbox Looking More Like a Toybox?

Managing Active Directory can get complicated.  Often, the native tools for managing AD are just not up to the task.  The largest Active Directory installations in the world have relied on one tool to manage their day-to-day administration tasks: Hyena. Start your trial today.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article describes a simple method to resize a control at runtime.  It includes ready-to-use source code and a complete sample demonstration application.  We'll also talk about C# Extension Methods. Introduction In one of my applications…
This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question