protected void SaveData(string IsDelete) { if ((hfIsUpdate.Value == "Y") || (IsDelete == "Y")) { hfID.Value = hfID.Value; } else { hfID.Value = ""; } timeSheetMgr.Insert_TimeSheetPolicy(hfID.Value, ddlYear.SelectedValue.ToString(), ddlMonth.SelectedValue.ToString(), txtHour.Text.Trim(), Session["USERID"].ToString(), Common.SetDateTime(DateTime.Now.ToString()), hfIsUpdate.Value, IsDelete); if ((hfIsUpdate.Value == "N") && (IsDelete == "N")) { lblMsg.Text = "Record Saved Successfully"; } else if ((hfIsUpdate.Value == "Y") && (IsDelete == "N")) { lblMsg.Text = "Record Updated Successfully"; } this.OpenRecord(); this.EntryText(); this.EntryMode(false); }