Unrecognized tag prefix or device filter 'asp'

Discussion in 'ASP .Net' started by =?Utf-8?B?U2hpdm9ubmU=?=, Jul 31, 2006.

  1. Hi all

    I am currently developing in VS .NET 2005. I am trying to create a master
    page but am getting the above error (Unrecognized tag prefix or device filter
    'asp') when trying to add a Content Placeholder control.

    My page source is as follows:

    <%@ Master Language="C#" AutoEventWireup="true"
    CodeBehind="MainSite.master.cs" Inherits="NBNZ.MasterPages.MainSite" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" >
    <head runat="server">
    <title>National Bank: Business Banking</title>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252" />
    <link href="/_private/style_lvl3.css" type="text/css" rel="stylesheet" />
    <asp:contentplaceholder id="_metaContent"
    runat="server"></asp:contentplaceholder>
    </head>
    <body>
    </body>
    </html>

    Can anyone help me with this, please?

    Thanks and kind regards

    Shivonne
    =?Utf-8?B?U2hpdm9ubmU=?=, Jul 31, 2006
    #1
    1. Advertising

  2. The first thing to try is this:

    1) close all VS instances and then delete the folder contents
    2) Folder:
    C:\Documents and Settings\[Username]\Application
    Data\Microsoft\VisualStudio\8.0\ReflectedSchemas

    in VS 2005 XML Schemas are automatically generatedthem using reflection on
    Web controls. So if something got "out of whack" that's where you want to
    get rid of the results and try letting them get regenerated.
    Peter




    --
    Co-founder, Eggheadcafe.com developer portal:
    http://www.eggheadcafe.com
    UnBlog:
    http://petesbloggerama.blogspot.com




    "Shivonne" wrote:

    > Hi all
    >
    > I am currently developing in VS .NET 2005. I am trying to create a master
    > page but am getting the above error (Unrecognized tag prefix or device filter
    > 'asp') when trying to add a Content Placeholder control.
    >
    > My page source is as follows:
    >
    > <%@ Master Language="C#" AutoEventWireup="true"
    > CodeBehind="MainSite.master.cs" Inherits="NBNZ.MasterPages.MainSite" %>
    > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    > <html xmlns="http://www.w3.org/1999/xhtml" >
    > <head runat="server">
    > <title>National Bank: Business Banking</title>
    > <meta http-equiv="Content-Type" content="text/html; charset=windows-1252" />
    > <link href="/_private/style_lvl3.css" type="text/css" rel="stylesheet" />
    > <asp:contentplaceholder id="_metaContent"
    > runat="server"></asp:contentplaceholder>
    > </head>
    > <body>
    > </body>
    > </html>
    >
    > Can anyone help me with this, please?
    >
    > Thanks and kind regards
    >
    > Shivonne
    =?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=, Jul 31, 2006
    #2
    1. Advertising

  3. Hi Peter

    Thanks for the quick response. I tried your solution below but it hasn't
    resolved the problem. I also tried deleting all the files in the Temporary
    ASP .NET Files folder under C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 but
    still no luck.

    Thanks

    Shivonne

    "Peter Bromberg [C# MVP]" wrote:

    > The first thing to try is this:
    >
    > 1) close all VS instances and then delete the folder contents
    > 2) Folder:
    > C:\Documents and Settings\[Username]\Application
    > Data\Microsoft\VisualStudio\8.0\ReflectedSchemas
    >
    > in VS 2005 XML Schemas are automatically generatedthem using reflection on
    > Web controls. So if something got "out of whack" that's where you want to
    > get rid of the results and try letting them get regenerated.
    > Peter
    >
    >
    >
    >
    > --
    > Co-founder, Eggheadcafe.com developer portal:
    > http://www.eggheadcafe.com
    > UnBlog:
    > http://petesbloggerama.blogspot.com
    >
    >
    >
    >
    > "Shivonne" wrote:
    >
    > > Hi all
    > >
    > > I am currently developing in VS .NET 2005. I am trying to create a master
    > > page but am getting the above error (Unrecognized tag prefix or device filter
    > > 'asp') when trying to add a Content Placeholder control.
    > >
    > > My page source is as follows:
    > >
    > > <%@ Master Language="C#" AutoEventWireup="true"
    > > CodeBehind="MainSite.master.cs" Inherits="NBNZ.MasterPages.MainSite" %>
    > > <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    > > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    > > <html xmlns="http://www.w3.org/1999/xhtml" >
    > > <head runat="server">
    > > <title>National Bank: Business Banking</title>
    > > <meta http-equiv="Content-Type" content="text/html; charset=windows-1252" />
    > > <link href="/_private/style_lvl3.css" type="text/css" rel="stylesheet" />
    > > <asp:contentplaceholder id="_metaContent"
    > > runat="server"></asp:contentplaceholder>
    > > </head>
    > > <body>
    > > </body>
    > > </html>
    > >
    > > Can anyone help me with this, please?
    > >
    > > Thanks and kind regards
    > >
    > > Shivonne
    =?Utf-8?B?U2hpdm9ubmU=?=, Jul 31, 2006
    #3
  4. =?Utf-8?B?U2hpdm9ubmU=?=

    IntrepidArch

    Joined:
    Aug 22, 2006
    Messages:
    2
    I too am experiencing this same problem. Have you found a solution?

    The strange part is that the asp:content tag works just fine, but no asp:... tags inside of it will work. And when the page is browsed, the asp:... tags get parsed just fine.

    I saw a bug report at M$ about this exact issue, but M$ said that nested masters don't work in the designer... even though we're not in the designer...
    IntrepidArch, Aug 22, 2006
    #4
  5. =?Utf-8?B?U2hpdm9ubmU=?=

    IntrepidArch

    Joined:
    Aug 22, 2006
    Messages:
    2
    Workaround

    I Found a Workaround

    I discovered that if you have the nested master page open at the same time, the child pages will work... there's M$ for you...

    Common.Master -can be closed
    Section1.Master -open
    Section1Child1.aspx -open
    IntrepidArch, Aug 22, 2006
    #5
  6. =?Utf-8?B?U2hpdm9ubmU=?=

    alphauzer

    Joined:
    Aug 28, 2006
    Messages:
    1
    I was experiencing the same problem. I eventually discovered that my @Page declaration was missing the MasterPageFile property. Once I added this property (MasterPageFile="MasterPage.master") everything worked as expected.

    Regards,
    alphauzer
    alphauzer, Aug 28, 2006
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Roger Helliwell
    Replies:
    2
    Views:
    775
    Roger Helliwell
    Nov 22, 2004
  2. Simon
    Replies:
    0
    Views:
    627
    Simon
    Nov 25, 2005
  3. Simon
    Replies:
    0
    Views:
    480
    Simon
    Nov 29, 2005
  4. Alan Silver
    Replies:
    0
    Views:
    482
    Alan Silver
    Jan 31, 2006
  5. Alan Silver
    Replies:
    0
    Views:
    1,703
    Alan Silver
    Feb 6, 2006
Loading...

Share This Page