protected void btnUpdate_Click(object sender, EventArgs e) { if (Page.IsValid) { BECourseAdmin objBEExamProvider = new BECourseAdmin(); BCourseAdmin objBExamProvider = new BCourseAdmin(); objBEExamProvider.IntStudentID = Convert.ToInt32(Session["studentid"]); objBEExamProvider.strFirstName = lblstudentfirstname.Text; objBEExamProvider.strLastName = lblStudentLastName.Text; //objBEExamProvider.strGenderName = ddlGender.SelectedValue; objBEExamProvider.strEmailAddress = lblEmailID.Text; // objBEExamProvider.strRoleName = lblrole.Text; objBEExamProvider.strPhoneNumber = txtPhoneNumber.Text; objBEExamProvider.strTimeZone = ddlTimeZone.SelectedValue; objBEExamProvider.strSpecialNeeds1 = ddlSpecialNeeds.SelectedValue; objBEExamProvider.StrComments = txtcomments.Value; objBExamProvider.BUpdateStudentDetails(objBEExamProvider); if (objBEExamProvider.IntResult == 1) { imgSuccess.Visible = true; trUpdate.Visible = true; EnableDetails(); //lblMsg.Text = "Student Details Updated Successfully"; lblMsg.Text = Resources.ResMessages.Provider_StudentUpdateSuccess; lblMsg.ForeColor = System.Drawing.Color.Green; imgCancel.Visible = true; imgUpdate.Visible = false; } else { //lblMsg.Text = "Please enter Valid Details"; lblMsg.Text = Resources.ResMessages.Provider_StudentUpdateFail; lblMsg.ForeColor = System.Drawing.Color.Red; imgCancel.Visible = true; imgUpdate.Visible = false; } } }
protected void btnUpdate_Click(object sender, EventArgs e) { if (Page.IsValid) { BECourseAdmin objBECourseAdmin = new BECourseAdmin(); BCourseAdmin objBCourseAdmin = new BCourseAdmin(); objBECourseAdmin.IntStudentID = Convert.ToInt32(Session["studentid"]); objBECourseAdmin.strFirstName = lblstudentfirstname.Text; objBECourseAdmin.strLastName = lblStudentLastName.Text; objBECourseAdmin.strEmailAddress = lblEmailID.Text; objBECourseAdmin.strSpecialNeeds1 = ddlSpecialNeeds.SelectedValue; objBECourseAdmin.StrComments = txtcomments.Value; objBECourseAdmin.IntstatusFlag = Convert.ToInt32(ddlStatus.SelectedValue.ToString()); objBCourseAdmin.BUpdateStudentDetails(objBECourseAdmin); if (objBECourseAdmin.IntResult == 1) { trUpdate.Visible = false; EnableDetails(); trMessage.Visible = true; lblInfo.Text = Resources.AppMessages.Provider_EditStudent_Success_StudentDetailsUpdated; lblInfo.ForeColor = System.Drawing.Color.FromName(Resources.AppConfigurations.Color_Success); ImgInfo.ImageUrl = Resources.AppConfigurations.Image_Success; tdInfo.Attributes.Add("style", Resources.AppConfigurations.Color_Table_Success); } else { trMessage.Visible = true; lblInfo.Text = Resources.AppMessages.Provider_EditStudent_Error_StudentDetails; lblInfo.ForeColor = System.Drawing.Color.FromName(Resources.AppConfigurations.Color_Error); ImgInfo.ImageUrl = Resources.AppConfigurations.Image_Error; tdInfo.Attributes.Add("style", Resources.AppConfigurations.Color_Table_Error); } } }