Centre for Software Practice

the blog
Welcome to Centre for Software Practice Sign in | Join | Help
in Search

David Glance's Blog

Using multiple MasterPageFiles in an application

We have an application that we have 2 skins for reflecting the 2 customers of the application. When I went to using skins, I defeined the MasterPageFile in the web.config file rather than switching it programmatically in each page. Unfortunately, this meant that every time I wanted to view a page in Visual Studio 2005, I had to put the MasterPageFile statement back in the page - an extremely tedious problem. Since then, I have discovered that it is relatively easy to set the MasterPageFile in the Page_PreInit method which retains the statement in the aspx file making viewing in the designer still possible. I think this problem is sort of fixed in VS 2008 but switching it programmatically means one less thing that needs to be changed in the config file.

Published Monday, 19 November 2007 1:07 PM by David.Glance
Filed under: ,

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

No Comments

Leave a Comment

(required) 
(optional)
(required) 
Submit
Powered by Community Server (Personal Edition), by Telligent Systems