Getting JQuery working

4 posts, 0 answers
  1. Aaron
    Aaron avatar
    7 posts
    Member since:
    Jul 2006

    Posted 08 Mar 2010 Link to this post

    I'm trying to get JQuery working.

    I am using RadControls for ASP.NET AJAX Q3 2009 NET35 and I have followed the instructions at http://www.telerik.com/help/aspnet-ajax/using-jquery.html but it seems that I have missed something because I keep getting 'Microsoft JScript runtime error: '$telerik' is undefined' when it gets to window.$ = $telerik.$

    What else am I missing?

    Thanks.

    <script type="text/javascript">  
     
        window.$ = $telerik.$;  
          
        $(document).ready(function() {  
            alert("start");  
        });  
     
        $(function() {  
            $('#tbPropAcqPropertyTax').calculator({  
                showOn: 'focus', buttonImageOnly: true, buttonImage: 'images/Calculator.gif'  
            })($telerik.$);  
        });  
    </script> 

         <telerik:RadScriptManager runat="server" ID="ScriptManager1">  
            <Scripts> 
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />   
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" /> 
                <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" /> 
                <asp:ScriptReference Path="JS/jquery.calculator.js" /> 
            </Scripts> 
          </telerik:RadScriptManager> 
  2. Veselin Vasilev
    Admin
    Veselin Vasilev avatar
    2992 posts

    Posted 09 Mar 2010 Link to this post

    Hello Aaron,

    You need to place that script below the ScriptManager's declaration. Otherwise it will try to use $telerik before the Telerik scripts are loaded.

    Kind regards,
    Veskoni
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
  3. DevCraft banner
  4. Aaron
    Aaron avatar
    7 posts
    Member since:
    Jul 2006

    Posted 09 Mar 2010 Link to this post

    Thank you, That worked.

    I found out that the nifty jQuery.calculator.js pluggin does not work with <telerik:RadTextBox> or <telerik:RadNumericTextBox>

    It only works with <asp:TextBox>
  5. Henri
    Henri avatar
    2 posts
    Member since:
    Apr 2012

    Posted 31 Jan 2014 Link to this post

    This fixed my problem!

    Thanks Veselin. I spent countles hours trying to resolve this.

    wmin
Back to Top