Override User Control...?
Summary: Basically I've localized my application and am trying to add in a asp style drop down list which has different languages to choose from, and on selection(postback) will change the pages language to whatever was selected. I'm trying to insert this drop down list into the header of my app. which has a compenentart style menu.
Problem: When I start doing the actual coding to make this function work i run into a problem. If my app. didn't have the compenentart user control I would just put in the following code:
Partial Class _Default
Inherits System.Web.UI.Page
Protected Overrides Sub InitializeCulture()
Dim lang As String = Request("DropDownList1")
If lang IsNot Nothing Or lang <> "" Then
Thread.CurrentThread.CurrentUICulture = New CultureInfo(lang)
Thread.CurrentThread.CurrentCulture = CultureInfo.CreateSpecificCulture(lang)
End If
End Sub
The problem is that since the page has user controls I obviously can use the " Inherits System.Web.UI.Page". B/C if i do change it to this and leave the rest of the code the same the app throws an error...it states, "sub 'InitializeCulture' cannot be declared 'Overrides' because it does not override a sub in a base class
Any thoughts, suggestions? I willing to go about this another way if possible...thanks in advanced