Version Française
Search Stories : Publier Votre Article
> VS 2008 ERROR Creating control in content pages (Unknown server tag) <
Published on 01/06/2008 By Malek Chtioui
I run into a bug in visual studio 2008 today, I haven’t found any solution on the web so I’ve decided to publish the solution here.

To test the new visual studio 2008 I’ve decided to migrate one of my projects visual studio 2005 (Framework 2.0 with Ajax and Ajaxcontroltoolkit) to the new Framework 3.5 using the visual studio 2008 (9.0).

Visual Studio invites me to upgrade my project, OK.  It compiles fine and runs at first try, GREAT!!!!

But then I opened the designer to check an aspx page, it display ‘Loading Master Page …’ then I got this error: ERROR Creating control : xxxxx Unknown server tag ‘xx:xxxx’

Ok, I’ve opened the master page, it works and displays without problem ????
I check the web.config, everything is ok : the control is declared <add tagPrefix="xx" namespace="xxxxxx" assembly="App_Code" />

After googeling a lot without success, I’ve checked for service packs, and I found the visual studio 2008 SP1 Beta1, and the .Net Framework SP1 Beta1, so I install them but the problem persists.

After re googeling again without success, I’ve decided to create a new empty project to test different possibilities, and I found a work around, the solution is very simple, but not so evident  : the master page must be open (in another tab) to be able to switch to design view in content pages!

Does Visual Studio 2008 function that way or it's a bug???
 Comments : Publish your article
It works
By Ashraf Sabry, Date: 19/01/2009
But every time you encounter the error, you must reopen the master page, then switch to design view in the content page.
Found an reason and solution!
By terrorix, Date: 10/08/2009
Hi there, i do research of this problem and found this. I have in web.config <pages theme="Office2003 Blue" styleSheetTheme="Office2003 Blue">. Important here are attributes 'theme' and 'styleSheetTheme'. If you do not have such themes in 'App_Themes' folder it seems to me that parsing of <controls element in <pages element is not proceed and thus custom control is not know for designer! Try to remove non existing 'theme' from <pages element and all it works like a charm. Interesing here is that this error is displayed only on aspx pages but not on ascx pages (on my enviroment).
Your solution worked for me too
By Asif, Date: 26/02/2010
I was facing the same issue, & followed the steps you mentioned & now seems to work. I did'nt understand what was wrong earlier. Anyway thanks a lot for sharing this info.
Thanxx ,it worked
By Arry , Date: 21/07/2010
Thanxx To Ashraf Sabry,
Iit solved the problem , thanxx a ton coz i was sick of it .
this is awesome
By jacob, Date: 08/06/2011
came stumbling on this from google and man did it save my time. excellent piece of work there ashraf.
 Add your Comment :
Your Name :
Email :
   * Email address will be hidden.
Title :
Comment :
Other articles
Hair Loss drug
 By Anshul Mahajan, Date : 28/08/2008
Where are my Kids [Picture]
 By Unk, Date : 18/04/2007
Egyptian Government Sites & Links
 By Xcess, Date : 24/03/2007
Sfax, Tunisia
 By Xcess, Date : 23/01/2007
5 Ways To Convert Anything to Anything
 By Malek Chtioui, Date : 22/06/2007
Top 5
Unlock your Nokia phone online for FREE.
 By Xcess, Date : 01/04/2007
A Program That Can Fix Dead Pixels On Your LCD Screen.
 By Malek Chtioui, Date : 14/06/2007
5 Ways To Convert Anything to Anything
 By Malek Chtioui, Date : 22/06/2007
Pictures of Dubai, a New City In Full Expansion
 By Malek Chtioui, Date : 12/06/2007
Request.Url parameters & details (Asp.net)
 By Malek Chtioui (Xcess), Date : 07/04/2008
Xcess Company, Adress : Xcess Company S.A.R.L., Boulevard Aïcha Bent Abi Backer, Khézama 3, Sousse, Tunisia.
Fax : (+216) 73 276 669 , Email/MSN : mail@xcess.info