tell me one thing:
How it is possible to know profTheme.Preferences.Theme of user that is seeing the page?
It has of being made a linking to the database, right?
With this code in basePage:
Protected Overrides Sub OnPreInit(ByVal e As System.EventArgs)
Dim id As String = Globals.ThemesSelectorID
If id.Length > 0 Then
Dim profTheme As ProfileCommon = HttpContext.Current.Profile
If Me.Request.Form("__EVENTTARGET") = id AndAlso _
Not String.IsNullOrEmpty(Me.Request.Form(id)) Then
Me.Theme = Me.Request.Form(id)
profTheme.Preferences.Theme = Me.Theme
If Not String.IsNullOrEmpty(profTheme.Preferences.Theme) Then
Me.Theme = profTheme.Preferences.Theme
The system make one connection to database(adding to all the others throughout the page) everytime the page is postback...
Are you sure this is a good strategy ?