You are viewing limited content. For full access, please sign in.

Question

Question

javascript - only able to retrieve values from row 1 of a table

asked on March 17, 2020

I'm trying to capture a value from any row in one column of a table, but it only works on the first row.  What am I doing wrong?  Thanks!

$ (document).ready(function () {

$(function() {
    $('[id^=Field153]').click(function () {
            alert($('[id^=Field153]').val());
    }); 
   });

});
 

 

 

0 0

Replies

replied on March 17, 2020 Show version history

Hi Sarah,

If your table does not have a fixed number of rows, then the following post should help explain the issue and how to get it working.

https://answers.laserfiche.com/questions/153832/Table-and-Collection-JavaScript-Event-Handlers

1 0
replied on March 17, 2020

Thanks you so much!  I'll try that out

1 0
You are not allowed to follow up in this post.

Sign in to reply to this post.