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

[Solved] Radgid Jquery not working between requests

1 Answer 107 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Paul
Top achievements
Rank 1
Paul asked on 07 Dec 2009, 12:09 PM
Hi,

Im having a problem with a JQuery function which is monitoring the radgrid when the page first loads the jquery does its job fine but if i send an ajax request to change the grid the jquery stops working! I looked atthe source before and after the request and the class the Jquery is looking for is applied ti the grid before and after request the jquery just isnt getting called after the request.

my jquery:

            (function($) { 
                $(document).ready(function() { 
                    $('.inputnormal').keydown(function(e) { 
                        if (e.keyCode == 46 || e.keyCode == 8 || e.keyCode == 9) { 
                            // let it happen, don't do anything 
                             
                        } 
                        else { 
                            // Ensure that it is a number and stop the keypress 
                            if (e.keyCode < 48 || e.keyCode > 57) { 
                                if (e.keyCode < 96 || e.keyCode > 105) { 
                                    e.preventDefault(); 
                                } 
                            } 
                        } 
                    }); 
                }); 
            })($telerik.$); 
Any ideas?

Thanks



1 Answer, 1 is accepted

Sort by
0
Pavlina
Telerik team
answered on 07 Dec 2009, 02:49 PM
Hi Paul,

The ajax events of the JQuery framework will be raised only when you trigger ajax request using the $.ajax method as explained in the JQuery online documentation:
http://docs.jquery.com/Ajax_Events

All the best,
Pavlina
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
Grid
Asked by
Paul
Top achievements
Rank 1
Answers by
Pavlina
Telerik team
Share this question
or