akhter says:
$("[id*=lblTotal]", row).html(parseFloat($(".grn_qty", row).html()) * parseFloat($(this).val()));
There is no element with class grn_qty in the row.
Also the Id of TextBox is lbtotal not lblTotal.
Refer the updated script.
<script type="text/javascript">
$(function () {
$("[id*=txtrate]").val("0");
});
$("body").on("change keyup", "[id*=txtrate]", function () {
//Check whether Quantity value is valid Float number.
var rate = parseFloat($.trim($(this).val()));
if (isNaN(rate)) {
rate = 0;
}
//Update the Quantity TextBox.
$(this).val(rate);
//Calculate and update Row Total.
var row = $(this).closest("tr");
$("[id*=lbtotal]", row).html(parseFloat($("td", row).eq(3).html()) * parseFloat($(this).val()));
//Calculate and update Grand Total.
var grandTotal = 0;
$("[id*=lbtotal]").each(function () {
grandTotal = grandTotal + parseFloat($(this).html());
});
$("[id*=lblGrandTotal]").html(grandTotal.toString());
});
</script>