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

Getting JQuery working

3 Answers 101 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Aaron
Top achievements
Rank 1
Aaron asked on 08 Mar 2010, 08:54 PM
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> 

3 Answers, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 09 Mar 2010, 02:53 PM
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.
0
Aaron
Top achievements
Rank 1
answered on 09 Mar 2010, 08:01 PM
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>
0
Henri
Top achievements
Rank 1
answered on 31 Jan 2014, 01:07 PM
This fixed my problem!

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

wmin
Tags
General Discussions
Asked by
Aaron
Top achievements
Rank 1
Answers by
Veselin Vasilev
Telerik team
Aaron
Top achievements
Rank 1
Henri
Top achievements
Rank 1
Share this question
or