how can stop navigation on the first row and on the last row of row selection from up and down keys?
how can stop navigation on the first row and on the last row of row selection from up and down keys?
immortalhemraj
Posts: 3Questions: 2Answers: 0
if (e.keyCode == 40){ //arrow down
table.$('tr.selected').removeClass('selected');
tr.next().addClass('selected');
tr = table.$('tr.selected');
}
if (e.keyCode == 38){ //arrow up
table.$('tr.selected').removeClass('selected');
tr.prev().addClass('selected');
tr = table.$('tr.selected');
}
data = table.row('tr.selected').data();
This discussion has been closed.
Answers
Hi @immortalhemraj ,
That's not possible I'm afraid - you can only limit the columns, not the rows. You could modify the source to get the effect you want in the KeyTables Js.
Cheers,
Colin
See if this example, using KeyTable, does what you want:
http://live.datatables.net/gaweheka/1/edit
The discussion is in this thread.
Kevin
thanks for helping me guys i got the solution till the size of the list it row selection will done from JQuery. Thankyou...