4 Replies Latest reply on Oct 10, 2012 1:59 PM by Giuliano Aparecido

    How to add/bind "oncomplete" event to rich:datascroller using javascript/jQuery

    Giuliano Aparecido Newbie

      Hi,

       

      I am having one problem: I need to add the "oncomplete" event to the rich:datascroller. Using the attribute works perfectly. The problem is that we have too many tables to change, so I was trying to use jQuery to bind the "oncomplete" event to the component.
      The script will run when the page is loading.

       

      I was trying something like:

       

      jQuery('.dr-dscr,.rich-datascr').bind('complete', function(){alert('test');});


      jQuery('.dr-dscr,.rich-datascr').bind('click', function(){jQuery.ajax({complete: function(){alert('test');}});});

       

      I am new in jQuery. Is it possible to bind the "oncomplete" event?
      Any idea?

       

      Basicaly, the "oncomplete" event will call another method from another script. So every time the user changes the page of the table, the method should be called.

       

      Thanks in advance