protected void ImageRemoveYes_Click(object sender, ImageClickEventArgs e) { try { string Delete = lclsservice.DeleteCorporateDetails(Convert.ToInt64(HiddenCorporateMasterID.Value), false, defaultPage.UserId); if (Delete == "Deleted Successfully") { EventLogger log = new EventLogger(config); log.LogWarning(msgerr.Replace("<<Corporate>>", HiddenCorporateName.Value)); ScriptManager.RegisterStartupScript(this, this.GetType(), "alert", Constant.CorporateDeleteMessage.Replace("<<Corporate>>", HiddenCorporateName.Value), true); BindGrid(); } } catch (Exception ex) { EventLogger log = new EventLogger(config); log.LogException(ex); ScriptManager.RegisterStartupScript(this, this.GetType(), "alert", Constant.CorporateErrorMessage.Replace("<<Corporate>>", ex.Message.ToString()), true); } }