Has anybody been working with 2.0 Skins and Themes?
I'm having a problem changing themes when attempting
to select a theme from a DropDownList and hope
somebody can suggest what is wrong with the branching
logic which seems to be the problem

The .aspx includes EnableTheming="true" in the page
directive.

The DDL AutoPostBack="true" and is briefly declared
as follows:

value="SelectStyleSheet" selected="True">
      Select A Style Sheet
value="red">
      Red Theme
value="green">
      Green Theme
value="blue">
      Blue Theme

The red theme should be loaded by default.
The following code does not change style sheets when
a selection is made from the DDL and I'd like to
learn what code should be used so the list item will
continue to show 'Select A Style Sheet' after each
selection...

void Page_PreInit(object sender, System.EventArgs e)
{
    if (ChangeStyleSheet.SelectedValue == "SelectStyleSheet")
        Page.Theme = "red";
    else
        Page.Theme = ChangeStyleSheet.SelectedValue.ToString(); 
}

<%= Clinton Gallagher





Yahoo! Groups Sponsor
ADVERTISEMENT
click here
Web Bug from http://us.adserver.yahoo.com/l?M=298184.5584357.6650215.3001176/D=groups/S=:HM/A=2426683/rand=339460537


Yahoo! Groups Links

Reply via email to