protected void DeleteRecord(object sender, ListViewDeleteEventArgs e) { string DrugID = ListView1.DataKeys[e.ItemIndex].Value.ToString(); ResultDTO resultDTO = objITransactionBusiness.DeleteMDrug(DrugID); if (resultDTO.IsSuccess) { pnlstatus.BackColor = System.Drawing.ColorTranslator.FromHtml(PHCConstant.SuccessBackGroundColor); lblstatus.ForeColor = System.Drawing.ColorTranslator.FromHtml(PHCConstant.SuccessForeColor); lblstatus.Text = resultDTO.Message; this.PopulateData(); } else { pnlstatus.BackColor = System.Drawing.ColorTranslator.FromHtml(PHCConstant.ErrorBackGroundColor); lblstatus.ForeColor = System.Drawing.ColorTranslator.FromHtml(PHCConstant.ErrorForeColor); lblstatus.Text = resultDTO.Message; } }