Culture

S

shapper

Hello,

I am working with VS 2008 and ASP.NET 3.5.

In my Web.Config file I have the following:

<globalization culture="pt-PT" uiCulture="pt-PT"/>

I suppose this sets the default culture of my web site.

All pages in my web site inherits from a master page named Base.

How can I, in Base.Master VB code, change the culture from the default
value to EN instead of changing in each page?

Thanks,
Miguel
 
C

Cowboy \(Gregory A. Beamer\)

shapper said:
Hello,

I am working with VS 2008 and ASP.NET 3.5.

In my Web.Config file I have the following:

<globalization culture="pt-PT" uiCulture="pt-PT"/>

I suppose this sets the default culture of my web site.

Yes. And it also states "no matter what the user wants, give him the default
language". Change to auto:pt-PT for both.
All pages in my web site inherits from a master page named Base.

How can I, in Base.Master VB code, change the culture from the default
value to EN instead of changing in each page?

me.Page.UICulture = ""

me.Page.Culture = ""

And set the proper name. This can be done in any event.

If you also want to change theme, you will have to do it in OnPreInit in the
base class. I believe you also have to bury master page changes here, as
well.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Culture. What am I doing wrong? 1
Culture 0
Date formats, culture and globalization 6
Culture 3
Default Culture in VS2008? 6
Culture Questions. en-US. 3
globalization settings 1
Page culture and Atlas Callback 0

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,534
Members
45,008
Latest member
Rahul737

Latest Threads

Top