protected void Page_Load(object sender, EventArgs e) { rwView.VisibleOnPageLoad = true; rwView.Visible = false; if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Leave Transaction", DateTime.Now); DateTime date = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 1); TxtFrmDate.Text = date.ToString("dd-MMM-yyyy ddd"); TxtToDate.Text = date.AddMonths(1).AddDays(-1).ToString("dd-MMM-yyyy ddd"); LoadTxns(); LoadBtn(); ViewState["postids"] = System.Guid.NewGuid().ToString(); Session["postid"] = ViewState["postids"].ToString(); } else { if (ViewState["postids"].ToString() != Session["postid"].ToString()) { IsPageRefresh = true; } Session["postid"] = System.Guid.NewGuid().ToString(); ViewState["postids"] = Session["postid"].ToString(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null) { Session.Abandon(); Response.Redirect("Login.aspx"); } if (!Page.IsPostBack) { if (!this.Page.User.Identity.IsAuthenticated) { FormsAuthentication.RedirectToLoginPage(); return; } UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Charts", DateTime.Now); divLeadSummary.Visible = false; divMR5.Visible = false; string strUserID = Session["UserID"].ToString(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null) { Response.Redirect("Login.aspx"); } else { LoadLKUP(); if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Leave Apply", DateTime.Now); if (Request.QueryString["RSN"].ToString() != "0") { LoadStaffId(); LoadReportHead(); LoadSaveTime(); Clear(); LoadData(); LoadStatus(); LoadLeaveType(); //LoadLeave(Session["StaffId"].ToString()); LoadHolidays(); LoadLeaveApply(); } } } }
protected void Page_Load(object sender, EventArgs e) { try { if (Session["UserID"] == null) { Session.Abandon(); Response.Redirect("Login.aspx"); } if (!IsPostBack) { if (!this.Page.User.Identity.IsAuthenticated) { FormsAuthentication.RedirectToLoginPage(); return; } UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Calendar", DateTime.Now); UserName = Session["UserID"].ToString(); strUserLevel = Session["UserLevel"].ToString(); } } catch (Exception ex) { WebMsgBox.Show(ex.Message.ToString()); } }
protected void Page_Load(object sender, EventArgs e) { rwROL.VisibleOnPageLoad = true; rwROL.Visible = false; rwNewLead.VisibleOnPageLoad = true; rwNewLead.Visible = false; rwStatusHelp.VisibleOnPageLoad = true; rwStatusHelp.Visible = false; rwReferenceHelp.VisibleOnPageLoad = true; rwReferenceHelp.Visible = false; if (Session["UserID"] == null) { Session.Abandon(); Response.Redirect("Login.aspx"); } rwReference.VisibleOnPageLoad = true; rwReference.Visible = false; if (!Page.IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Home", DateTime.Now); string currPage = System.IO.Path.GetFileName(Request.Url.AbsolutePath); Session["HomePage"] = Request.Url.GetLeftPart(UriPartial.Authority) + Request.ApplicationPath + "/" + currPage; LoadDashBoard(); ChkLeaveSystem(); LoadUserLevel(); btnCSave.Attributes.Add("onclick", "javascript:return Validate();"); btnROLSave.Attributes.Add("onclick", "javascript:return ROlmsg();"); //ContentPage.Attributes.Add("onkeypress", "javascript:return clickButton(event,'" + ibtnSearch.ClientID + "');"); dvRadWindow.Visible = false; LoadProspectTypes(); LoadMsg(); LoadCampaignMsg(); GetApptCounts(); LoadComplaintsDetails(); txtSearch.Focus(); if (Session["AlertMsg"] != null) { Session["AlertMsg"] = null; WebMsgBox.Show("Please recharge quickly to avoid disconnecting."); } } }
protected void Page_Load(object sender, EventArgs e) { Session["PayUser"] = null; if (!Page.IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Pay Login", DateTime.Now); } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Holidays", DateTime.Now); LoadHType(); LoadHStatus(); LoadGrid(); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null) { Session.Abandon(); Response.Redirect("Login.aspx"); } string strcnfresultid = CnfResult.ClientID.ToString(); QSUserName = Session["UserID"].ToString(); HDLoginUser.Value = Session["UserID"].ToString(); rwDiary.VisibleOnPageLoad = true; rwDiary.Visible = false; rwCustomerProfile.VisibleOnPageLoad = true; rwCustomerProfile.Visible = false; rwBulkUpdate.VisibleOnPageLoad = true; rwBulkUpdate.Visible = false; rwHelp.VisibleOnPageLoad = true; rwHelp.Visible = false; if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "My Tasks", DateTime.Now); lnkmytasks.ForeColor = Color.DarkBlue; lnkbyme.ForeColor = Color.LightGray; lnknewactiviy.ForeColor = Color.DarkGray; if (!this.Page.User.Identity.IsAuthenticated) { FormsAuthentication.RedirectToLoginPage(); } LoadDDL1(); LoadTrackOn(); LoadMasters(); AddAttributes(); ddlTaskList1.SelectedIndex = 1; btnMyTasks_Click(sender, e); } }
protected void Page_Load(object sender, EventArgs e) { if (Session["UserID"] == null) { Response.Redirect("Login.aspx"); } else { if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Leave Allow", DateTime.Now); LoadStaff(); LoadForMonth(); LoadGrid(); } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Leave Approve", DateTime.Now); if (Request.QueryString["RSN"].ToString() != "0") { //LoadStaffId(); LoadTxnType(); //LoadStatus(); //LoadReportHead(); //LoadSaveTime(); //Clear(); //LoadData(); //LoadLeave(Session["StaffId"].ToString()); LoadHolidays(); LoadView(Convert.ToInt16(Request.QueryString["RSN"])); } } }
protected void Page_Load(object sender, EventArgs e) { SQLProcs sqlobj = new SQLProcs(); DataSet dsDT = null; ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page); rwSaveTime.VisibleOnPageLoad = true; rwSaveTime.Visible = false; rwHelp.VisibleOnPageLoad = true; rwHelp.Visible = false; rwReferenceHelp.VisibleOnPageLoad = true; rwReferenceHelp.Visible = false; dtpFollowupdate.MinDate = DateTime.Today; dtpTargetDate.MinDate = DateTime.Today; rwNewLead.VisibleOnPageLoad = true; rwNewLead.Visible = false; if (!IsPostBack) { if (!this.Page.User.Identity.IsAuthenticated) { FormsAuthentication.RedirectToLoginPage(); return; } UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "New Task", DateTime.Now); UserID = Session["UserID"].ToString(); //dsDT = sqlobj.SQLExecuteDataset("GetServerDateTime"); //lblDate.Text = Convert.ToDateTime(dsDT.Tables[0].Rows[0][0].ToString()).ToString("dd-MMM-yyyy | hh:mm tt"); ; dtpAssignOnDate.SelectedDate = DateTime.Now.Date; dtpTargetDate.SelectedDate = DateTime.Now.AddDays(3); //LoadCompleInDays(); if (Session["TaskType"] == null) { TaskType = "FromDirect"; } else { TaskType = Session["TaskType"].ToString(); } if (TaskType == "FromDirect") { LoadCustomer(); LoadTrackOn(); } else if (TaskType == "FromProspect") { LoadProspectCustomer(); ddlCustName.SelectedValue = Session["ProspectRSN"].ToString(); ddlCustName.Enabled = false; ddlType.Enabled = false; LoadTrackOn(); LoadContactNames(); Session["TaskType"] = "FromDirect"; } //LoadCustomer(); LoadAssignedTo(); //LoadTrackOn(); //LoadTaskType(); LoadAssignedBy(); //LoadStatus(); LoadPriority(); // LoadComplexity(); LoadCustStatus(); LoadSaveTime(); LoadUserLevel(); LoadProspectTypes(); //LoadCheckList(); ddlNewLeadType.Enabled = false; txtNotes.Text = "New Lead"; if (Request.QueryString["Group"] != null) { ddlReferenceGroup.SelectedValue = "Marketing"; ddlTrackon.SelectedValue = "#Aptmnt"; dtpFollowupdate.SelectedDate = Convert.ToDateTime(Request.QueryString["Date"].ToString()); ddlReferenceGroup.Enabled = false; ddlTrackon.Enabled = false; dtpFollowupdate.Enabled = false; } } }
protected void btnUpd_Click(object sender, EventArgs e) { if (txtConfirmPwd.Text != string.Empty && txtCurrentPwd.Text != string.Empty && txtPassword.Text != string.Empty && txtConfirmPwd.Text != string.Empty) { UserMenuLog uml = new UserMenuLog(); uml.InsertUserMenuLog(Session["UserID"].ToString(), "Change Password", DateTime.Now); if (txtPassword.Text == txtConfirmPwd.Text) { try { SQLProcs proc = new SQLProcs(); DataSet ds = new DataSet(); ds = proc.SQLExecuteDataset("SP_GETDTLS", new SqlParameter() { ParameterName = "@IMODE", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.Int, Value = 1 } , new SqlParameter() { ParameterName = "@UserID", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.NVarChar, Value = txtCPUserID.Text }, new SqlParameter() { ParameterName = "@PWD", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.NVarChar, Value = txtCurrentPwd.Text }); if (ds != null && ds.Tables[0].Rows.Count > 0) { if (ds.Tables[0].Rows.Count == 0) { WebMsgBox.Show("Kindly check your User ID."); return; } if (txtCurrentPwd.Text == ds.Tables[0].Rows[0]["Password"].ToString()) { proc.SQLExecuteDataset("SP_CHANGEPASSWORD", new SqlParameter() { ParameterName = "@IMODE", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.Int, Value = 1 } , new SqlParameter() { ParameterName = "@RSN", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.BigInt, Value = Convert.ToInt64(ds.Tables[0].Rows[0]["RSN"]) }, new SqlParameter() { ParameterName = "@PWD", Direction = ParameterDirection.Input, SqlDbType = SqlDbType.NVarChar, Value = txtConfirmPwd.Text }); WebMsgBox.Show("Password Changed Successfully"); //AutoEmail(); //InsertUsageLog(); } else { WebMsgBox.Show("Kindly check your current password"); return; } } } catch (Exception ex) { WebMsgBox.Show(ex.Message); } } else { WebMsgBox.Show("Error! New password and Confirm Password do not match. Please re-enter."); } } else { WebMsgBox.Show("Enter Mandatory Field"); } }