Click here to Skip to main content
15,924,935 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: how to use asp.net page on web Pin
George L. Jackson28-Nov-06 15:29
George L. Jackson28-Nov-06 15:29 
GeneralRe: how to use asp.net page on web Pin
trannguyen8628-Nov-06 15:37
trannguyen8628-Nov-06 15:37 
GeneralRe: how to use asp.net page on web Pin
George L. Jackson28-Nov-06 15:51
George L. Jackson28-Nov-06 15:51 
GeneralRe: how to use asp.net page on web Pin
George L. Jackson28-Nov-06 15:53
George L. Jackson28-Nov-06 15:53 
GeneralRe: how to use asp.net page on web Pin
trannguyen8628-Nov-06 15:56
trannguyen8628-Nov-06 15:56 
GeneralRe: how to use asp.net page on web Pin
trannguyen8628-Nov-06 16:01
trannguyen8628-Nov-06 16:01 
GeneralRe: how to use asp.net page on web Pin
George L. Jackson28-Nov-06 16:06
George L. Jackson28-Nov-06 16:06 
QuestionNested Master Pages Pin
shapper28-Nov-06 14:06
shapper28-Nov-06 14:06 
Hello,

I am creating a web site with Nested Master pages.

I also need to have a class where the culture is set. When the culture is changed by the user the page refreshes and the change takes effect.
I saw this approach, I think, on a MSDN web site or blog:

Config.vb > Class where culture is set from profile value

_Base.master > Parent master page

( _Navigation > Child master page)

Default.aspx.vb > Page

I have this working without the child master page _Navigation. I can't make this work with the child master page.

Could someone help me out with this?

This is the code for my 3 working pages (Config.vb, _Base.master and Defaul.aspx.vb)

----- Config.vb -----

1 Public Class Config
2 Inherits Page
3
4 Sub Page_PreInit(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.PreInit
5 Response.Write("Config")
6 Page.Theme = CType(Context.Profile, ProfileCommon).Config.Theme
7 End Sub
8
9 Protected Overrides Sub InitializeCulture()
10 MyBase.InitializeCulture()
11 Dim language As String = CType(Context.Profile, ProfileCommon).Config.Language
12 If (language IsNot Nothing) AndAlso (language <> "Auto") Then
13 MyBase.UICulture = language
14 Thread.CurrentThread.CurrentCulture = CultureInfo.CreateSpecificCulture(language)
15 End If
16 End Sub
17
18 End Class



----- Base.master.vb -----

1 Partial Class _Base
2 Inherits System.Web.UI.MasterPage
3
4 Protected Sub Page_Init(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Init
5 Response.Write("Base.master")
6 End Sub
7
8 End Class
9
10



----- Default.aspx.vb -----

1 Partial Class _Default
2 Inherits Config
3
4 Protected Overloads Sub Page_PreInit(ByVal sender As Object, ByVal e As EventArgs) Handles Me.PreInit
5 Me.MasterPageFile = "~/_Base.master"
6 End Sub
7
8 Protected Sub Page_Init(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Init
9 Response.Write("Default.aspx")
10 End Sub
11
12 End Class

Could someone help me out in integrating a Child Master page between _Base.master and Default.aspx?

Thanks,

Miguel
QuestionDataview...adding additional columns Pin
jimNLX28-Nov-06 13:33
jimNLX28-Nov-06 13:33 
AnswerRe: Dataview...adding additional columns Pin
Not Active28-Nov-06 14:57
mentorNot Active28-Nov-06 14:57 
QuestionMissing link (groan sorry) Pin
DanB198328-Nov-06 10:03
DanB198328-Nov-06 10:03 
AnswerRe: Missing link (groan sorry) Pin
Bassam Saoud28-Nov-06 10:17
Bassam Saoud28-Nov-06 10:17 
AnswerRe: Missing link (groan sorry) Pin
trannguyen8628-Nov-06 15:29
trannguyen8628-Nov-06 15:29 
QuestionRegEx Validator Pin
Chris Losinger28-Nov-06 9:12
professionalChris Losinger28-Nov-06 9:12 
AnswerRe: RegEx Validator Pin
ednrgc28-Nov-06 9:30
ednrgc28-Nov-06 9:30 
Questiondeleting the records Pin
saravanan0528-Nov-06 8:53
saravanan0528-Nov-06 8:53 
AnswerRe: deleting the records Pin
ednrgc28-Nov-06 8:56
ednrgc28-Nov-06 8:56 
GeneralRe: deleting the records Pin
saravanan0528-Nov-06 9:21
saravanan0528-Nov-06 9:21 
GeneralRe: deleting the records Pin
trannguyen8628-Nov-06 15:22
trannguyen8628-Nov-06 15:22 
AnswerRe: deleting the records Pin
Not Active28-Nov-06 17:53
mentorNot Active28-Nov-06 17:53 
QuestionMysterious behaviour Pin
lnu0128-Nov-06 8:47
lnu0128-Nov-06 8:47 
AnswerRe: Mysterious behaviour Pin
ednrgc28-Nov-06 8:55
ednrgc28-Nov-06 8:55 
GeneralRe: Mysterious behaviour [modified] Pin
lnu0128-Nov-06 9:28
lnu0128-Nov-06 9:28 
AnswerRe: Mysterious behaviour Pin
Guffa28-Nov-06 9:08
Guffa28-Nov-06 9:08 
GeneralRe: Mysterious behaviour [modified] Pin
lnu0128-Nov-06 9:44
lnu0128-Nov-06 9:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.