Reputation: 7
I have a column in a grid that contains dropdown list. The row also has a link which takes me to an action method. I need the selected value of the dropdown list in that row and pass it to the method.
I have used jquery in the past to get the selected value of a dropdown list...but not when there are multiple drop down lists. Can you give me some ideas on how I could resolve this?
Upvotes: 0
Views: 352
Reputation: 888303
It sounds like you're trying to write
$(this).closest('tr').find('select.SomeClass').val()
This code will get the <tr>
containing this
, then find a select
in the row.
Upvotes: 2