This is a migrated thread and some comments may be shown as answers.

asp:ScriptReference problem

5 Answers 383 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bob
Top achievements
Rank 1
Bob asked on 21 Jul 2008, 04:02 PM
<telerik:RadScriptManager ID="RadScriptManager1" Runat="server">
        <Scripts>
            <asp:ScriptReference Assembly="" Name="" Path="~/js/AjaxExceptionHandling.js" />
        </Scripts>
    </telerik:RadScriptManager>

Error:

Error    15    System.Web.UI.ScriptReferenceCollection must have items of type 'System.Web.UI.ScriptReference'. 'asp:ScriptReference' is of type 'System.Web.UI.ScriptReference'.    C:\Development\Website\Main.aspx    82   

Why would I receive this error?  The last thing I did was upgrade from v415 to v619.

5 Answers, 1 is accepted

Sort by
0
Accepted
Todd Anglin
Top achievements
Rank 2
answered on 21 Jul 2008, 04:15 PM
Bob-

Sorry to see you're having trouble. Your code snippet looks correct. You can obviously remove the unused "Assembly" and "Name" properties from your ScriptReference, but otherwise things look okay.

Have you tried debugging this problem yet? If not, I'd suggest trying a couple of things:

  1. Try using a "regular" ScriptManager to see if that solves the problem. If it does, then...
  2. Try re-adding the Telerik ScriptManager. If that re-breaks the page, then...
  3. Try re-adding the older version of the Telerik ScriptManager. If that works then we've found a problem with the version you're using.
Give those things a try and let me know what you find.

-Todd
0
Bob
Top achievements
Rank 1
answered on 21 Jul 2008, 06:03 PM
The standard ScriptManager worked, and both errors were resolved when I re-added the RadScriptManager (via Design view) to one of the pages.

Thanks!
0
Todd Anglin
Top achievements
Rank 2
answered on 21 Jul 2008, 06:51 PM
Bob-

Good to hear. Sounds like there must have just been a problem with the register directive on the page, or even more likely with the temporary ASP.NET files on your PC. Good luck on the rest of your project!

-Todd
0
Joseph Alves
Top achievements
Rank 1
answered on 18 Aug 2008, 03:26 PM
Had the same here and I've just found out why :  the system.web.extension was not referenced in my project. Once I referenced it, everything came back to normal.
0
Hector
Top achievements
Rank 1
answered on 20 May 2010, 02:34 PM
Had exact same problem and fixed it by:
  1.  adding a regular asp scriptmanager,
  2. building the project,
  3. deleting asp:scriptmanager
  4. adding RadScriptManager and referencing the scripts
Thanks for the sugestion, Todd!
Tags
General Discussions
Asked by
Bob
Top achievements
Rank 1
Answers by
Todd Anglin
Top achievements
Rank 2
Bob
Top achievements
Rank 1
Joseph Alves
Top achievements
Rank 1
Hector
Top achievements
Rank 1
Share this question
or