change the theme in VS2005 or VS2008

要在PreInit Event前做改动

Another Method, in the application PreRequestHandlerExcute
void Application_PreRequestHandlerExecute(object sender, EventArgs e)
{
    Page page 
= Context.Handler as Page;

    
if (page == null)
        
return;

    
//Get the theme
    
   
    page.PreInit 
+= delegate
   
{
        page.Theme 
= theme; 
        
        
//Update the cookie 
    }
;
}


不过这个方法还要配合其它代码来一起实现才可以
原文地址:https://www.cnblogs.com/forward/p/1027081.html