DATATABLE select row issue [Solved]

DATATABLE select row issue [Solved]

H2wkH2wk Posts: 14Questions: 0Answers: 0
edited October 2011 in DataTables 1.8
Hi

So loving datatables but currently having an issue with the select event at the moment.
[code]
$('#table_id tbody tr').click(function () {
var aPos = oTable.fnGetPosition(this);
var aData = oTable.fnGetData(aPos)[0]
sendDataToServer('PERSONCLICK_' + aData);
});
[/code].

The code above works 100% on first pageload and first row click.

I have a jquery tabstrip that loads data relating to the selected row...

The moment I change the tab and the select a new row from the gird i get an error:

"Microsoft JScript runtime error: Unable to get value of the property '0': object is null or undefined"

and [code] oTable.fnGetPosition(this) [/code] returns null.

Any suggestions or comments?

(I am using async callback to load the grid)

I do have more than one datatable on the page. the second one of which is only populated when a specific tab is clicked.

Replies

  • H2wkH2wk Posts: 14Questions: 0Answers: 0
    After some more digging i realized i had assigned the 2nd data table to the same table element as the first... sigh... oh well all fixed...
This discussion has been closed.