views:

186

answers:

3

I just started working on a new International project. All strings in the markup of ASPX pages are instead System.Web.UI.WebControls.Localize controls with "meta:resourcekey=" attributes. In the web root there's a App_LocalResources and in a App_GlobalResources, but the strings in all resource files are all English.

Where is the web site getting the International language-strings? Is there some built-in translator for ASP.NET? Where should I look to see the unicode foreign language characters?

+1  A: 

There is no built in translator.

You should see resource files for each .aspx page in the App_LocalResources folder. For each .aspx file, there will be multiple resources files, one for each translation, with different file names like:

AddCustomer.aspx.resx
AddCustomer.aspx.fr.resx
AddCustomer.aspx.en-US.resx

etc. etc. Each file contains the translation for the culture given in the filename.

womp
If you don't see the files, make sure "Show all files" is enabled. Maybe they're on the disk but not in the solution.
Greg
A: 

When you have a Page or User Control open in design view there's an option to localize off the Tools menu (I think). That'll create an App_LocalResources folder in whatever folder your currently working in. The App_LocalResources in the root will be for pages in the root of the website. App_GlobalResources is for your web.sitemap and any other resources you wish to use throughout the entire site.

I set up sub folders within App_LocalResources for each language.

For example, some pages:

Default.aspx Create.aspx View.aspx

-> App_LocalResources // folder

Default.aspx.resx // default language is picked up if browser's preferences not satisfied. Create.aspx.resx View.aspx.resx

--> DE// sub folder for german

Default.aspx.de.resx Create.aspx.de.resx View.aspx.de.resx

--> FR// sub folder for french

Default.aspx.fr.resx Create.aspx.fr.resx View.aspx.fr.resx

I've never had to do anything to specify a particular country's brand of a language (outside of displaying currenceis that is) but if you needed Austrian German say then you could do this.

--> DE-AT// sub folder for Austrian german

Default.aspx.de-AT.resx Create.aspx.de-AT.resx View.aspx.de-AT.resx

Mark Holland
A: 

It's also possible that a custom resource provider has been created (this is the best thing to do when dealing with a largish site/program). There's an overview of resource providers here which might help you track down what's happen if the resx files are genuinely nowhere to be found.

FinnNk