Chenna Rao Chenna Rao - 7 months ago 37
jQuery Question

How to get gridview entire cell values inside html textbox onchange="return Calculations(this);" jQuery function

I am trying to inside gridview html textbox values enter, when it loses focus(mean jQuery

onchange="return fuction()"
) side I would like to know which row of the table it is in. Mean that entire cell values detail required any idea ?

<asp:TemplateField HeaderText="Adjusting time(HH:MM:SS)">
<div class="form-group">
<div class="col-md-3">
<input id="txtHours" runat="server" type="text"
class="form-control" placeholder="HH"
onchange="return Calculations(this);" />
<div class="col-md-3">
<input id="txtMinutes" runat="server" type="text"
class="form-control" placeholder="MM"
onchange="return Calculations(this);" />
<div class="col-md-3"></div>


enter image description here

 function Calculations(elem) {
            var TabChangeId = $(elem).attr("id");
            if (TabChangeId == "txtHours") {
                var CurrentNode = $(elem).parent().parent().parent().parent();
                var EmpName = CurrentNode.find('#lblEmployeename').text();

click of hours or minutes and seconds get that row values.