12 Replies Latest reply on Mar 10, 2009 12:40 AM by venkat reddy

    not get datatable in javascript func after reRender the tabl

    venkat reddy Newbie

      hi,

      iam using richfaces datatables in my application.
      when i click on a row in datatable i call contextmenu and doing my action.
      after complete my action iam calling the javascript through oncomplete attribute in menuItem.
      but iam getting null when i try to get the datatable object.

      iam using like:

      <ri:menuItem submitMode="ajax"
      action="#{myaction}"
      reRender="table"
      oncomplete="reset('table')" >

      function reset(txt)
      {
      var t=document.getElementById(txt);
      alert(t);
      }

      txt has value of datatable name and its fine.
      but i am getting null when i get this with document.getEById.

      how can i get the table object here in javasctript