Ambiguous

Rate It (1)

Last post 12-04-2009 5:51 AM by Gadiputi sudhir. 25 replies.

Sort Posts:

  • Ambiguous

    12-26-2007, 12:13 PM
    • Member
      52 point Member
    • kyleq
    • Member since 08-03-2006, 9:42 PM
    • Posts 54

    At various times I get an error message telling me that the server tag "asp:ScripManager is " is ambiguous.  It may also happen with other tags including UpdateProgress and UpdatePanel.  How do I fix this?

    I am running Visual Web Developer 2008 with Framework Version 3.5.

  • Re: Ambiguous

    12-26-2007, 12:46 PM
    • Contributor
      6,882 point Contributor
    • pixelsyndicate
    • Member since 07-04-2003, 12:56 PM
    • W. MI transplant in N. TX
    • Posts 1,206

    Does your ScriptManager code contain an unique ID and a runat property?

    <asp:ScriptManager ID="ScriptManager1" runat="server">

    Please click 'Mark as Answer' if my reply has assisted you.

    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools." ~ Douglas Adams

    http://wildobson.com
  • Re: Ambiguous

    12-26-2007, 2:01 PM
    • Member
      52 point Member
    • kyleq
    • Member since 08-03-2006, 9:42 PM
    • Posts 54

    Yes.  That phrase occurs on several pages.

    Kyle

  • Re: Ambiguous

    12-26-2007, 2:13 PM
    • Contributor
      6,882 point Contributor
    • pixelsyndicate
    • Member since 07-04-2003, 12:56 PM
    • W. MI transplant in N. TX
    • Posts 1,206

    ok. that ambiguous error generally comes to you when you have two assemblies (DLL's) in your bin file which define the scriptmanager.

    Does your error mention a particular namespace (like Microsoft.Web.UI or MicrosoftWEb.Extensions.dll)?

     

    Please click 'Mark as Answer' if my reply has assisted you.

    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools." ~ Douglas Adams

    http://wildobson.com
  • Re: Ambiguous

    12-26-2007, 6:11 PM
    • Member
      52 point Member
    • kyleq
    • Member since 08-03-2006, 9:42 PM
    • Posts 54

    The message says "The server tag 'asp:ScriptManager' is ambiguous.  Please midify the associated registration that is causing ambiguity and pick a new tag preference.  The fiel is Post.aspx line 3.  Line 3 is printed below.

    <%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"

    Namespace="System.Web.UI" TagPrefix="asp" %>

     The line below is where the reference to ScriptManager takes place.  Highlighting the word ScriptManager brings the following information.

    Element ScriptManager is not a know element.  This can occur if there is a compilation error in the web site or if the web.config file is missing.

    <asp:ScriptManager id="ScriptManager1" runat="server">

     

  • Re: Ambiguous

    12-27-2007, 9:15 AM
    • Contributor
      6,882 point Contributor
    • pixelsyndicate
    • Member since 07-04-2003, 12:56 PM
    • W. MI transplant in N. TX
    • Posts 1,206

    kyleq:

    The message says "The server tag 'asp:ScriptManager' is ambiguous.  Please midify the associated registration that is causing ambiguity and pick a new tag preference.  The fiel is Post.aspx line 3.  Line 3 is printed below.

    <%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"

    Namespace="System.Web.UI" TagPrefix="asp" %>

     The line below is where the reference to ScriptManager takes place.  Highlighting the word ScriptManager brings the following information.

    Element ScriptManager is not a know element.  This can occur if there is a compilation error in the web site or if the web.config file is missing.

    <asp:ScriptManager id="ScriptManager1" runat="server">

    Hmmm.. I wonder if this means your System.Web.Extensions have been registered twice, once in the aspx source code and once in your web.config file... please delete the scriptmanager from your page, delete the above register line from your page, and attempt to recompile. It should error. now drag a scriptmanager back onto the page. Did the Register line get placed back in the page? Try to recompile. 

    Please click 'Mark as Answer' if my reply has assisted you.

    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools." ~ Douglas Adams

    http://wildobson.com
  • Re: Ambiguous

    12-27-2007, 10:59 AM
    • Member
      52 point Member
    • kyleq
    • Member since 08-03-2006, 9:42 PM
    • Posts 54

    As you suggested I deleted the scriptmanager and the registration line went away and so did that error.  I re-created the script manager and the registration line came back and so did the error.

    I get a total of 3 errors on this page. 

    The server tag 'asp:ScriptManager' is ambiguous.  Please modify the associated registration that is causing ambiguity and pick a new tag prefix.

    The server tag 'asp: UpdatePanel' is ambiguous.  the rest is the same

    The server tag 'asp:UpdateProgress' is ambiguous.  The rest of the line is the same.

    What do you suggest.

     

  • Re: Ambiguous

    12-27-2007, 11:13 AM
    • Contributor
      6,882 point Contributor
    • pixelsyndicate
    • Member since 07-04-2003, 12:56 PM
    • W. MI transplant in N. TX
    • Posts 1,206

    try modifying these lines in the following way: asp > myasp

     

    <%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"

    Namespace="System.Web.UI" TagPrefix="myasp" %>

     

    <myasp:ScriptManager id="ScriptManager1" runat="server">

    Please click 'Mark as Answer' if my reply has assisted you.

    "A common mistake that people make when trying to design something completely foolproof was to underestimate the ingenuity of complete fools." ~ Douglas Adams

    http://wildobson.com
  • Re: Ambiguous

    12-27-2007, 5:04 PM
    • Member
      52 point Member
    • kyleq
    • Member since 08-03-2006, 9:42 PM
    • Posts 54

    That did not work. 

    However, I have extracted the downloaded the ClubExtended V2 source several more times.  If I open the web using VWD 2005 with the 2.0 framework I get no errors.  If I use VWD 2008 with the 2.0 framework I also get a clean web.  However, If I convert to Framework 3.5 as it asks me to do when I first open the web then the errors occur.

    It seems it is the conversion from Framework version 2.0 to 3.5 that is causing the problem.  I just won't do that conversion.

    Thanks for all your help.

  • Re: Ambiguous

    01-21-2008, 8:00 PM
    • Member
      4 point Member
    • prichards14
    • Member since 01-22-2008, 12:52 AM
    • Posts 2

    Has anyone found a solution to this problem?  My situation is a little different, but I am experiencing the same result.  I develop module for the DotNetNuke content management system in Asp.Net.  I created a simple module in Visual Studio 2005 with AJAX using system.web.extensions.dll and it works fine.  When I create the same module code in a fresh project in Visual Studio 2008 I get this error:


    DotNetNuke.Services.Exceptions.ModuleLoadException: E:\Inetpub\wwwroot\KA3\DesktopModules\Test\Main.ascx(8): error BC30560: 'UpdatePanel' is ambiguous in the namespace 'System.Web.UI'. ---> System.Web.HttpCompileException: E:\Inetpub\wwwroot\KA3\DesktopModules\Test\Main.ascx(8): error BC30560: 'UpdatePanel' is ambiguous in the namespace 'System.Web.UI'. at System.Web.Compilation.BuildManager.CompileWebFile(VirtualPath virtualPath) at System.Web.Compilation.BuildManager.GetVPathBuildResultInternal(VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.Compilation.BuildManager.GetVPathBuildResultWithNoAssert(HttpContext context, VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile) at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath) at System.Web.UI.TemplateControl.LoadControl(String virtualPath) at DotNetNuke.UI.Skins.Skin.InjectModule(Control objPane, ModuleInfo objModule, PortalSettings PortalSettings) --- End of inner exception stack trace ---

    I removed system.web.extensions.dll from the bin folder and I still get the error.  I really have no idea how to fix this.  It appears that somehow the UpdatePanel control is defined in two different copies of the web.system.ui namespace.

    Any suggestions will be greatly appreciated.  Visual Studio 2008 is unusable for me until I can get past this.

    Thanks!
    -Pat

     

  • Re: Ambiguous

    01-23-2008, 4:43 AM
    • Member
      2 point Member
    • bij004
    • Member since 05-28-2007, 1:33 PM
    • Posts 2

    Hi

    Try to change the line

    <add assembly="System.Web.Extensions, Version=xxxx, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>to

     

    <add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>

    In your Web.config file

  • Re: Ambiguous

    02-27-2008, 12:07 PM

    Did you guys ever reach a solution for this?

  • Re: Ambiguous

    03-05-2008, 8:55 AM
    • Member
      57 point Member
    • Sleb
    • Member since 02-19-2007, 8:31 PM
    • Posts 55

     If you run on .Net 3.5  in your config file , in the <controls> section add this line

     <add namespace="AjaxControlToolkit" assembly="AjaxControlToolkit" tagPrefix="ajaxToolkit"/>

     Then replace your scriptmanager by this one (don't forget to remove the <%@register ... line at the top

     <ajaxToolkit:ToolkitScriptManager ID="ScriptManager1" runat="server" />

    It should work.

     
    If you run on .Net 2.0 it maybe caused by the fact that Ajax is not installed on your server. Simply copy the System.Web.Extensions.dll & System.Web.Extensions.Design.dll into the Bin folder of your app.

    (usually if you installed ajax at the default location on your machine these files can be found here C:\Program Files\Microsoft ASP.NET\ASP.NET 2.0 AJAX Extensions\v1.0.61025 ).

     


                   




     

  • Re: Ambiguous

    03-14-2008, 7:40 PM
    • Member
      2 point Member
    • reevev
    • Member since 08-13-2007, 1:26 AM
    • Posts 1

     You should find that ajax 3.5 is registered in your controls section of web.config. If you remove the line:

     <%@ Register Assembly="System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
       Namespace="System.Web.UI" TagPrefix="asp" %>

    from the top  of the page where you are getting the error everything should be fine as the asp prefix registered in the web.config will kick in and correctly reference ajax 3.5.

  • Re: Ambiguous

    05-15-2008, 3:39 PM
    • Member
      22 point Member
    • iamtgo3
    • Member since 05-22-2006, 8:37 PM
    • Posts 23

    Here is what I had to do to fix it. If you added the code to your web.config file like below you may have to take it out I did.

    <!-- As shown for using AJAX on VS 2005 -->
    
    <sectionGroup name="system.web.extensions" type="System.Web.Configuration.SystemWebExtensionsSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
      <sectionGroup name="scripting" type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    	<section name="scriptResourceHandler" type="System.Web.Configuration.ScriptingScriptResourceHandlerSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
          <sectionGroup name="webServices" type="System.Web.Configuration.ScriptingWebServicesSectionGroup, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
    	<section name="jsonSerialization" type="System.Web.Configuration.ScriptingJsonSerializationSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="Everywhere"/>
    	<section name="profileService" type="System.Web.Configuration.ScriptingProfileServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    	<section name="authenticationService" type="System.Web.Configuration.ScriptingAuthenticationServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
    	<section name="roleService" type="System.Web.Configuration.ScriptingRoleServiceSection, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" allowDefinition="MachineToApplication"/>
          </sectionGroup>
        </sectionGroup>
      </sectionGroup>
    </configSections>
    
    <controls>
      <add tagPrefix="asp" namespace="System.Web.UI" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add namespace="AjaxControlToolkit" assembly="AjaxControlToolkit" tagPrefix="ajaxToolkit"/>
      <add tagPrefix="asp" namespace="System.Web.UI.WebControls" assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    </controls>
    
    <httpHandlers>
      <add verb="*" path="*.asmx" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add verb="*" path="*_AppService.axd" validate="false" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
      <add verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" validate="false"/>--><!--
    httpModules>
      <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    </httpModules>
    
    <system.webServer>
      <validation validateIntegratedModeConfiguration="false"/>
        <modules>
    	<remove name="ScriptModule"/><add name="ScriptModule" preCondition="managedHandler" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </modules>
        <handlers>
    	<remove name="ScriptHandlerFactory"/>
    	<remove name="ScriptHandlerFactoryAppServices"/>
    	<remove name="ScriptResource"/><remove name="WebServiceHandlerFactory-Integrated"/>
    	<add name="ScriptHandlerFactory" verb="*" path="*.asmx" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    	<add name="ScriptHandlerFactoryAppServices" verb="*" path="*_AppService.axd" preCondition="integratedMode" type="System.Web.Script.Services.ScriptHandlerFactory, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
    	<add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD" path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        </handlers>
    </system.webServer>

     

    Then I had to delete the controls created in VS2005. Install the new AjaxControlToolkit-Framework3.5. Also install the new AjaxControlExtender.vsi found in the "AjaxControlToolkit-Framework3.5\AjaxControlExtender" folder. Then delete all your script managers and now click on the icons that have the AJAX controls set to them and ADD and Extender. This is if you used toolkit controls and not ones you have made. I did however have a few little issues with other software vendors.

    George - (iamtgo3) www.ipdg3.com
    (AS / CADD / CompTIA A+ Certified / CompTIA Network+ Certified / MCSA / MCP / MCT)
    Helping Developers and Programmers Find Resources
Page 1 of 2 (26 items) 1 2 Next >