hi friends,
i have one grid view with alternate color row in asp.net MVC. i also include delete and edit functionality to each row but after deleting one row the color is not maintain well means sequence of alternate row is miss mach so it create bad row design what should i do to solve this problem.
following is the image before deleting ...

Manoj BhoirPosted Jun 15, 2015, 8:32 AM
Manoj BhoirPosted Jun 15, 2015, 8:47 AM
Amit SamnaniPosted Jun 15, 2015, 8:43 AM
Amit SamnaniPosted Jun 15, 2015, 8:19 AM
Manoj BhoirPosted Jun 15, 2015, 6:10 AM
$("tr:odd").css("background", "#ededed");
// $("#divGrid").load('/Settings/DomainSettings #divGrid');
$("tr:odd").css("background", "#ededed");
document.getElementById("txtSearch").value = "Enter your search
Amit SamnaniPosted Jun 15, 2015, 6:08 AM
Amit SamnaniPosted Jun 15, 2015, 6:05 AM
var DomainId = $("#hdnId").val();
var DomainId1 = $("#hdnId1").val();
var Searchtxt = "";
var NextCount = 1;
var ParamData = { DomainId: DomainId }
$.ajax({
url: "/Settings/DeleteDomain",
type: "POST",
data: JSON.stringify(ParamData),
dataType: "json",
contentType: "Application/json; charset=utf-8",
success: function (result) {
HidePopUp('DivDeleteConfirm', 'blur');
var PopUp = document.getElementById("DivDeleteConfirm2");
var blur = document.getElementById("blur");
SetBlurDiv(PopUp, blur);
$("tr:odd").css("background", "#ededed");
// $("#divGrid").load('/Settings/DomainSettings #divGrid');
$("tr:odd").css("background", "#ededed");
document.getElementById("txtSearch").value = "Enter your search here...";
document.getElementById("grdLeadQueue").deleteRow(DomainId1);
$("#hdnId").val(0);
NxtCount = 1;
//$("#divGrid").load('/Settings/LoadOnScroll?Searchstr=' + Searchtxt + '&NextCount=' + NextCount + ' #divGrid');
// $("tr:odd").css("background", "#ededed");
},
error: function (data) {
if (data.status === 401) {
Logout();
return;
}
},
complete: function () {
// $("tr:odd").css("background", "#ededed");
}
});
// $("tr:odd").css("background", "#ededed");
}
Manoj BhoirPosted Jun 14, 2015, 2:47 AM