Can we make each of the individual rows in the DataTable clickable?

Can we make each of the individual rows in the DataTable clickable?

SKCSKC Posts: 33Questions: 10Answers: 0

I'm currently using server-side processing and have mapped the DataTable with data from SQL Server DB.

My question is :
Can we make each of the rows clickable?
**For e.g. **when I click on first row it should redirect me to a new page
where it shows detailed information about the contents on that row. Then when I click on second row it should redirect me to new page and so on....

Is it possible and if yes, how?

Replies

  • allanallan Posts: 63,540Questions: 1Answers: 10,476 Site admin

    Can we make each of the rows clickable?

    Sure - use a jQuery event:

    $('#myTable').on( 'click', 'tr', function () {
      ...
    } );
    

    Allan

  • SKCSKC Posts: 33Questions: 10Answers: 0

    Got it.
    Thanks Allan

This discussion has been closed.