protected void btnValidate_Click(object sender, EventArgs e) { if (Page.IsValid) { try { BStudent objBStudent = new BStudent(); BEStudent objBEStudent = new BEStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID].ToString()); objBEStudent.strAnswer1 = txtAnswer1.Text.Trim().ToString(); objBEStudent.strAnswer2 = txtAnswer2.Text.Trim().ToString(); objBEStudent.strAnswer3 = txtAnswer3.Text.Trim().ToString(); objBStudent.BValidateStudentSecurityQuestions(objBEStudent); if (objBEStudent.IntResult == 1) { // Response.Redirect("ExamConfig.aspx?" + Request.QueryString.ToString(),false); Response.Redirect("Agreements.aspx?" + Request.QueryString.ToString(), false); } else { // ScriptManager.RegisterStartupScript(this, this.GetType(), "ShowSuccess", "alert('Invalid Security Answers, Please try again')", true); //lblFailed.Text = "Invalid Security Answers, Please try again"; lblFailed.Text = Resources.ResMessages.Student_InvalidSecAns; } } catch (Exception) { // ErrorLog.WriteError(Ex); } } }
protected void btnContinue_Click(object sender, EventArgs e) { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); objBStudent.BGetIdentityValidation(objBEStudent); if (objBEStudent.StudentIdentity) { Response.Redirect("ValidateStudent.aspx?" + Request.QueryString.ToString(), false); } else { lblError.Visible = true; } } catch (Exception) { //ErrorLog.WriteError(Ex); } }
protected void BindSecurityQuestions() { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = 0; objBStudent.BBindProfileSecurityQuestions(objBEStudent); if (objBEStudent.DsResult.Tables[0].Rows.Count > 0) { Session["Dataset"] = objBEStudent.DsResult; ddlSecurityQuestion1.Items.Add(new Telerik.Web.UI.RadComboBoxItem("-- Select Security question --", "-1")); ddlSecurityQuestion1.AppendDataBoundItems = true; ddlSecurityQuestion1.DataSource = objBEStudent.DsResult.Tables[0]; ddlSecurityQuestion1.DataTextField = objBEStudent.DsResult.Tables[0].Columns[1].ToString(); ddlSecurityQuestion1.DataValueField = objBEStudent.DsResult.Tables[0].Columns[0].ToString(); ddlSecurityQuestion1.DataBind(); ddlSecurityQuestion1.SelectedValue = "-1"; ddlSecurityQuestion2.Items.Add(new Telerik.Web.UI.RadComboBoxItem("-- Select Security question --", "-1")); ddlSecurityQuestion3.Items.Add(new Telerik.Web.UI.RadComboBoxItem("-- Select Security question --", "-1")); } } catch (Exception) { // ErrorLog.WriteError(Ex); } }
protected void CheckMyProfile() { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]); objBStudent.BValidateUploadandQuestions(objBEStudent); if (objBEStudent.DsResult != null && objBEStudent.DsResult.Tables.Count > 0 && objBEStudent.DsResult.Tables[0].Rows.Count > 0) { if (Convert.ToInt32(objBEStudent.DsResult.Tables[0].Rows[0]["PhotoCheck"]) == 1 && Convert.ToInt32(objBEStudent.DsResult.Tables[0].Rows[0]["QuestionsCheck"]) == 1 && Convert.ToInt32(objBEStudent.DsResult.Tables[0].Rows[0]["TimeZoneCheck"]) == 1) { tblContent.Visible = true; tblMyProfile.Visible = false; lblMyprofile.Text = string.Empty; } else { tblContent.Visible = false; tblMyProfile.Visible = true; lblMyprofile.Text = Resources.ResMessages.Student_MyProfileCheck; } } else { tblContent.Visible = false; } }
protected void getPhotoIdentity() { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]); objBStudent.BgetPhotoIdentity(objBEStudent); if (objBEStudent.DtResult.Rows.Count > 0) { //img.ImageUrl = "~/Student\\Student_Identity\\" + objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString(); img.ImageUrl = new AppSecurity().ImageToBase64(objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString()); img.ImageAlign = ImageAlign.Top; // string strTotalPath = Server.MapPath(img.ImageUrl); string strTotalPath = Server.MapPath("~/Student\\Student_Identity\\" + objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString()); FileInfo fi = new FileInfo(strTotalPath); if (fi.Exists) { System.Drawing.Image image = System.Drawing.Image.FromFile(strTotalPath); int width = 0; int height = 0; if (image != null) { width = image.Width; height = image.Height; if (height > 183) { img.Height = Unit.Pixel(183); img.Width = Unit.Pixel(292); } else if (height < 183) { img.Height = height; img.Width = width; } } else { img.ImageUrl = "~/Student\\Student_Identity\\noimage.jpg"; } } else { img.ImageUrl = "~/Student\\Student_Identity\\noimage.jpg"; } } else { img.ImageUrl = "~/Student\\Student_Identity\\noimage.jpg"; } } catch (Exception) { } }
public MStudentType() { if (_bll == null) { _bll = new BStudent(); } Field(d => d.Id).Description("学号"); Field(d => d.Name).Description("学生名"); Field(d => d.Age).Description("年龄"); Field(d => d.Birthdate).Description("生日"); Field <MClassType>("sclass", resolve: d => { //缓存中已经存在就直接返回 if (d.Source.SClass != null) { return(d.Source.SClass); } //从DB/缓存中获取数据 var classId = d.Source?.ClassId ?? 0; if (classId > 0) { d.Source.SClass = _bll.GetClass(d.Source.ClassId); } return(d.Source.SClass); }, description: "班级信息"); }
protected void btnnext_Click(object sender, EventArgs e) { if (Request.QueryString["TransID"] != null) { Int64 TransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = TransID; objBEStudent.IntFlag = Convert.ToInt32(frompage); objBStudent.BGetAuthenticationOverrideStatus(objBEStudent); if (objBEStudent.DtResult.Rows.Count > 0 && objBEStudent.DtResult.Rows[0][0].ToString() != "") { if (TYPE == "1") { if (objBEStudent.DtResult.Rows[0][0].ToString() == "AGREE") { Response.Redirect("StudentAgreements.aspx?TransID=" + Request.QueryString["TransID"].ToString() + "&&ExamiKEY=" + AppSecurity.Encrypt("1"), false); } else if (objBEStudent.DtResult.Rows[0][0].ToString() == "KEY") { Response.Redirect("studentexamiKEY.aspx?TransID=" + Request.QueryString["TransID"].ToString() + "&&ExamiKEY=" + AppSecurity.Encrypt("1"), false); } } else { if (objBEStudent.DtResult.Rows[0][0].ToString() == "AGREE") { Response.Redirect("StudentAgreements.aspx?TransID=" + Request.QueryString["TransID"].ToString() + "&&ExamiKEY=" + AppSecurity.Encrypt("0"), false); } } } } }
protected void getPhotoIdentity() { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]); objBStudent.BgetPhotoIdentity(objBEStudent); if (objBEStudent.DtResult.Rows.Count > 0) { string strTotalPath = Server.MapPath("~/Student\\Student_Identity\\" + objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString()); if (File.Exists(strTotalPath)) { //img.Src = "~/Student\\Student_Identity\\" + objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString(); img.Src = new AppSecurity().ImageToBase64(objBEStudent.DtResult.Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString()); } else { img.Src = "../Images/noimage.png"; } } else { img.Src = "../Images/noimage.png"; } } catch (Exception) { } }
protected void Page_Load(object sender, EventArgs e) { //btnProceed.Attributes.Add("onclick", "return browserValidate();"); ((LinkButton)this.Page.Master.FindControl("lnkStart")).CssClass = "main_menu_active"; if (Request.QueryString.ToString() != "") { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BGetExamSessionID(objBEStudent); BindSecurityQuestions(); BindStep4Details(); this.GetAllRules(); GetProviderFile(); //GetSessionID(); } else { //Show errors if any } //Get exam details for browser-lockdown signal new CommonFunctions().setExamDetailsForExamityMeeting(Request.QueryString["TransID"].ToString(), hdnIsLockDown, hdnIsPasswordExists, hdnLmsDomain, hdnExamSecurity); ScriptManager.RegisterStartupScript(this, this.GetType(), "NotSaved", "document.getElementById('" + imgHead.ClientID.ToString() + "').focus();", true); }
protected void LoadData() { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[EnumPageSessions.USERID].ToString()); objBEStudent.IntProviderID = 0; objBStudent.BGetStudentTodayExams(objBEStudent); if (objBEStudent.DtResult.Rows.Count > 0) { ViewState["SecurityLevels"] = objBEStudent.DtResult; gvStartExam.DataSource = objBEStudent.DtResult; gvStartExam.Visible = true; objBEStudent = null; objBStudent = null; } else { lblMsg.Visible = true; lblMsg.Text = "You do not have any exams scheduled. <a href='ScheduleAnExam.aspx'><u><font color='blue'>Schedule an exam</font></u></a> and it will show up here."; gvStartExam.DataSource = new object[] { }; gvStartExam.Visible = false; } } catch (Exception Ex) { throw Ex; } }
protected void btnValidate_Click(object sender, EventArgs e) { BEStudent objbestudent = new BEStudent() { strPassword = txtCode.Text.Trim(), IntTransID = Convert.ToInt64(ViewState["TransID"]) }; BStudent objbstudent = new BStudent(); objbstudent.BValidateAuthenticationCode(objbestudent); if (objbestudent.IntResult == 1) { tbl1.Visible = false; tbl2.Visible = false; tbl3.Visible = true; lblresult.Text = "Code successfully verified."; BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(ViewState["TransID"]); objBEStudent.IntType = 16; objBStudent.BUpdatePLTime(objBEStudent); Response.Redirect("Agreements.aspx?TransID=" + AppSecurity.Encrypt(ViewState["TransID"].ToString()), false); } else { tbl1.Visible = false; tbl2.Visible = true; tbl3.Visible = true; lblresult.Text = "Invalid code, please try again."; txtCode.Text = ""; } }
public void GetProviderFile() { if (Request.QueryString.ToString() != "") { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BgetProviderFile(objBEStudent); if (objBEStudent.DsResult != null && objBEStudent.DsResult.Tables.Count > 0 && objBEStudent.DsResult.Tables[0].Rows.Count > 0) { gvUploadFiles.DataSource = objBEStudent.DsResult.Tables[0]; gvUploadFiles.DataBind(); gvUploadFiles.Visible = true; } else { //ExamFiles.Visible = false; gvUploadFiles.DataSource = new string[] { }; gvUploadFiles.DataBind(); gvUploadFiles.Visible = false; } } else { //ExamFiles.Visible = false; } }
protected void LoadData() { try { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[EnumPageSessions.USERID].ToString()); objBEStudent.IntProviderID = 0; objBEStudent.strExamName = string.Empty; objBStudent.BGetStudentTransactions(objBEStudent); if (objBEStudent.DtResult.Rows.Count > 0) { gvStudentHome.DataSource = objBEStudent.DtResult; } else { gvStudentHome.DataSource = new object[] { }; objBEStudent = null; objBStudent = null; } } catch (Exception Ex) { throw Ex; } }
private void GetEditForm(Appointment editedAppointment) { Appointment appointmentToEdit = ExamScheduler.PrepareToEdit(editedAppointment, ExamScheduler.EditingRecurringSeries); if (editedAppointment.ID == null) { StartTime.SelectedDate = ExamScheduler.UtcToDisplay(appointmentToEdit.Start); } else { string[] str = appointmentToEdit.Subject.Split('['); lblCourse.Text = str[0].ToString(); string[] str1 = str[1].Split(']'); lblExam.Text = str[1].Substring(0, str[1].Length - 1).ToString(); lblExam.Text = str1[0].ToString(); // lblSubjectValue.Text = str[0].ToString() + " [ " + str1[0].ToString() + " ] "; BEStudent obj = new BEStudent(); obj.IntExamID = 0; obj.IntTransID = Convert.ToInt64(appointmentToEdit.ID.ToString()); BStudent obj1 = new BStudent(); obj1.BGetExamStartEndDates(obj); if (obj.DtResult != null && obj.DtResult.Rows.Count > 0) { lblSubjectValue.Text = obj.DtResult.Rows[0]["ExamMins"].ToString() + " minutes"; } lblExamIDValue.Text = appointmentToEdit.ID.ToString(); //txtDescription.Text = appointmentToEdit.Description; StartTime.SelectedDate = ExamScheduler.UtcToDisplay(appointmentToEdit.Start); } }
protected void ImageButton1_Click(object sender, ImageClickEventArgs e) { BStudent bll = new BStudent(); Student st = new Student( Convert.ToString(TextBox1.Text), Convert.ToString(TextBox2.Text), Convert.ToString(TextBox3.Text), Convert.ToString(TextBox4.Text) ); //BHomework HLL = new BHomework(); //Homework h = new Homework( // Convert.ToString(TextBox3.Text), // Convert.ToString(TextBox1.Text) // ); if (Page.IsValid) { bll.InsertStudent(st); //HLL.InsertHomework(h); Response.Write("<script>alert('添加成功!');location='StudentAdd.aspx'</script>"); } else { Response.Write("<script>alert('添加失败!');</script>"); } }
protected void gvUploadFiles_ItemCommand(object sender, GridCommandEventArgs e) { if (e.CommandName == "Delete") { try { string StoredFileName = e.CommandArgument.ToString(); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(Request.QueryString["TransID"]); objBEStudent.strOriginalFileName = StoredFileName; System.IO.FileInfo objFileName = new System.IO.FileInfo(Server.MapPath(System.Configuration.ConfigurationManager.AppSettings["StudentUploads"]) + "\\" + StoredFileName); if (objFileName.Exists) { objFileName.Delete(); objBStudent.BStudentDeleteUploadedFile(objBEStudent); } else { //ScriptManager.RegisterStartupScript(this, this.GetType(), "NotSaved", "alert('File doesnot exist');", true); Page.ClientScript.RegisterStartupScript(GetType(), "MyScript", "alert('File deletion failed.Please try again.');", true); } gvUploadFiles.Rebind(); trMessage.Visible = false; } catch (Exception) { } } }
//the following function is used to display the uploaded files in the grid for auto authentication exam public void GetProviderFile() { if (Request.QueryString.ToString() != "") { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BgetProviderFile(objBEStudent); if (objBEStudent.DsResult != null && objBEStudent.DsResult.Tables.Count > 0 && objBEStudent.DsResult.Tables[0].Rows.Count > 0) { gvUploadFiles.DataSource = objBEStudent.DsResult.Tables[0]; gvUploadFiles.DataBind(); gvUploadFiles.Visible = true; } else { gvUploadFiles.DataSource = new string[] { }; gvUploadFiles.DataBind(); gvUploadFiles.Visible = false; } if (objBEStudent.DsResult != null && objBEStudent.DsResult.Tables.Count > 0 && objBEStudent.DsResult.Tables[1].Rows.Count > 0) { if (objBEStudent.DsResult.Tables[1].Rows[0]["ExamPassword"].ToString() == "") { divpassword.Attributes.Add("style", "display:none"); } else { divpassword.Attributes.Add("style", "display:block"); txtpassword.Text = objBEStudent.DsResult.Tables[1].Rows[0]["ExamPassword"].ToString(); } } } }
/// <summary> /// Exam Approved - Student : Approved By Proctor /// </summary> /// <param name="TransID"></param> public void ExamApprovedStudent(Int64 TransID, string strStatus) { stbEmail = new StringBuilder(); stbEmail.Append("<table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" >"); stbEmail.Append("<tr><td><img src=\"http://demo.secureproctor.com/images/logo.png\" />"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Dear @STUDENTNAME,</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); if (strStatus == "Approved") { stbEmail.Append("<tr><td>Congratulations! Your @EXAMNAME is successfully Approved by Auditor.</td></tr>"); } else if (strStatus == "Rejected") { stbEmail.Append("<tr><td>Unfortunately, the @EXAMNAME exam is Rejected by Auditor.</td></tr>"); } stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Your Exam Information</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>ID : @EXAMID</td></tr>"); stbEmail.Append("<tr><td>Course Name : @COURSENAME</td></tr>"); stbEmail.Append("<tr><td>Exam Name : @EXAMNAME</td></tr>"); stbEmail.Append("<tr><td>Date : @DATE</td></tr>"); stbEmail.Append("<tr><td>Time : @TIME (local time)</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Thanks,</td></tr>"); stbEmail.Append("<tr><td>Examity Team.</td></tr>"); stbEmail.Append("<tr><td>Examity LLC. ALL RIGHTS RESERVED.</td></tr>"); stbEmail.Append("<tr><td>Contact Us: [email protected]</td></tr>"); stbEmail.Append("<tr><td>***<b>DO NOT REPLY TO THIS EMAIL</b>***</td></tr>"); stbEmail.Append("<tr><td></td></tr></table>"); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = TransID; objBStudent.BGetStudentExamDetails(objBEStudent); stbEmail.Replace("@EXAMID", TransID.ToString()); stbEmail.Replace("@STUDENTNAME", objBEStudent.DtResult.Rows[0]["Name"].ToString()); stbEmail.Replace("@COURSENAME", objBEStudent.DtResult.Rows[0]["CourseName"].ToString()); stbEmail.Replace("@EXAMNAME", objBEStudent.DtResult.Rows[0]["ExamName"].ToString()); stbEmail.Replace("@DATE", objBEStudent.DtResult.Rows[0]["ExamDate"].ToString()); stbEmail.Replace("@TIME", objBEStudent.DtResult.Rows[0]["TimeDuration"].ToString()); stbEmail.Replace("@URL", "http://ProctorVaultV3.strateology.net/login.aspx"); //this.SendMail(stbEmail.ToString(), "Exam is " + strStatus.ToLower().ToString() + " by Auditor"); if (strStatus == "Approved") { this.SendMail(stbEmail.ToString(), "Examity: " + objBEStudent.DtResult.Rows[0]["ExamName"].ToString() + " [" + TransID.ToString() + "] Approval Confirmation"); } else if (strStatus == "Rejected") { this.SendMail(stbEmail.ToString(), "Examity: " + objBEStudent.DtResult.Rows[0]["ExamName"].ToString() + " [" + TransID.ToString() + "] Exam Rejected by Auditor"); } }
protected void btnEdit_Click(object sender, EventArgs e) { lblsucc.Visible = false; trSecurityQuestionsView.Visible = false; trSecurityQuestionsEdit.Visible = true; ddlSecurityQuestion1.Items.Clear(); ddlSecurityQuestion2.Items.Clear(); ddlSecurityQuestion3.Items.Clear(); BindSecurityQuestions(); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]); objBStudent.BBindProfileSecurityQuestions(objBEStudent); if (objBEStudent.DsResult.Tables[1].Rows.Count > 0) { if (objBEStudent.DsResult.Tables[1].Rows[0]["Qid1"].ToString() != string.Empty) { ddlSecurityQuestion1.SelectedValue = objBEStudent.DsResult.Tables[1].Rows[0]["Qid1"].ToString(); } else { ddlSecurityQuestion1.SelectedValue = "-1"; } if (objBEStudent.DsResult.Tables[1].Rows[1]["Qid1"].ToString() != string.Empty) { ddlSecurityQuestion2.SelectedValue = objBEStudent.DsResult.Tables[1].Rows[1]["Qid1"].ToString(); } else { ddlSecurityQuestion2.SelectedValue = "-1"; } if (objBEStudent.DsResult.Tables[1].Rows[2]["Qid1"].ToString() != string.Empty) { ddlSecurityQuestion3.SelectedValue = objBEStudent.DsResult.Tables[1].Rows[2]["Qid1"].ToString(); } else { ddlSecurityQuestion3.SelectedValue = "-1"; } if (txtAnswer1.Text != string.Empty) { txtAnswer1.Text = objBEStudent.DsResult.Tables[1].Rows[0]["QAnswer1"].ToString(); } if (txtAnswer2.Text != string.Empty) { txtAnswer2.Text = objBEStudent.DsResult.Tables[1].Rows[1]["QAnswer1"].ToString(); } if (txtAnswer3.Text != string.Empty) { txtAnswer3.Text = objBEStudent.DsResult.Tables[1].Rows[2]["QAnswer1"].ToString(); } } ScriptManager.RegisterStartupScript(this, this.GetType(), "NotSaved", "document.getElementById('" + Label4.ClientID.ToString() + "').focus();", true); }
public string GetIsexamiFACEDownLoad() { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); objBStudent.BCheckIsexamiFACEDownLoad(objBEStudent); return(objBEStudent.DtResult.Rows[0]["IsexamiFACE"].ToString());; }
protected void bindGOTOMeetingLink() { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BGetExamSessionID(objBEStudent); lnk.Attributes.Add("onclick", "openwin('" + System.Configuration.ConfigurationManager.AppSettings["GOTOMeetingLink"].ToString() + objBEStudent.strSessionID); }
protected void gvStartExam_ItemCommand(object sender, GridCommandEventArgs e) { string[] commandArgs = e.CommandArgument.ToString().Split(new char[] { ',' }); if (commandArgs[1].ToString() == "5") // LEVEL AA { if (commandArgs[2].ToString() != "1") { Session["isexamiFACE"] = "0"; Response.Redirect("Systemreadiness.aspx?TransID=" + AppSecurity.Encrypt(commandArgs[0].ToString()), false); } else { Session["isexamiFACE"] = "0"; Response.Redirect("Systemreadiness.aspx?TransID=" + AppSecurity.Encrypt(commandArgs[0].ToString()), false); } } else { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[EnumPageSessions.USERID].ToString()); objBEStudent.IntTransID = Convert.ToInt64(commandArgs[0].ToString()); objBStudent.BCheckExamStartTime(objBEStudent); if (objBEStudent.DtResult != null && objBEStudent.DtResult.Rows.Count > 0) { if (Convert.ToInt32(objBEStudent.DtResult.Rows[0]["Result"]) == 1) { objBStudent.BSetStudentStartExamFlag(objBEStudent); if (Convert.ToBoolean(objBEStudent.DtResult.Rows[0]["isexamiFACE"]) == true) { Session["isexamiFACE"] = "1"; this.CaptureOsAndBrowser(Convert.ToInt64(commandArgs[0].ToString())); Response.Redirect("Systemreadiness.aspx?TransID=" + AppSecurity.Encrypt(commandArgs[0].ToString()), false); } else if (Convert.ToBoolean(objBEStudent.DtResult.Rows[0]["ExamiKey"]) == true) { Session["isexamiFACE"] = "0"; this.CaptureOsAndBrowser(Convert.ToInt64(commandArgs[0].ToString())); Response.Redirect("StudentExamProcess.aspx?TransID=" + AppSecurity.Encrypt(commandArgs[0].ToString()) + "&&ExamiKEY=" + AppSecurity.Encrypt("1"), false); } else { Session["isexamiFACE"] = "0"; this.CaptureOsAndBrowser(Convert.ToInt64(commandArgs[0].ToString())); Response.Redirect("StudentExamProcess.aspx?TransID=" + AppSecurity.Encrypt(commandArgs[0].ToString()) + "&&ExamiKEY=" + AppSecurity.Encrypt("0"), false); } tderror.Visible = false; } else { tderror.Visible = true; lblError.Text = "<img src='../Images/no.png'align='middle'/> <font color='red'>" + Resources.ResMessages.Student_checkStartTime + "</font>"; } } } }
//#region Common ///// <summary> ///// Forgot Password ///// </summary> ///// <param name="strStudent"></param> //public void ForgotPassword(string strUserID, string Password) //{ // stbEmail = new StringBuilder(); // stbEmail.Append("<table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" >"); // stbEmail.Append("<tr><td><img src=\"http://demo.secureproctor.com/images/logo.png\" />"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>Dear @STUDENTNAME,</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>You have requested a password reset for Secure Proctor account " + strUserID + "</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>New Password: "******"</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>Thanks,</td></tr>"); // stbEmail.Append("<tr><td>Secure Proctor Team.</td></tr>"); // stbEmail.Append("<tr><td>Secure Proctor LLC. ALL RIGHTS RESERVED.</td></tr>"); // stbEmail.Append("<tr><td>Contact Us: [email protected]</td></tr>"); // stbEmail.Append("<tr><td>***<b>DO NOT REPLY TO THIS EMAIL</b>***</td></tr>"); // stbEmail.Append("<tr><td></td></tr></table>"); // BEStudent objBEStudent = new BEStudent(); // BStudent objBStudent = new BStudent(); // objBEStudent.IntUserID = strUserID; // objBStudent.BGetUserName(objBEStudent); // stbEmail.Replace("@STUDENTNAME", objBEStudent.DtResult.Rows[0]["FirstName"].ToString() + " " + objBEStudent.DtResult.Rows[0]["LastName"].ToString()); // //this.SendMail(stbEmail.ToString(), "BAT: Forgot Password"); // this.SendMail(stbEmail.ToString(), "Secure Proctor: Secure Proctor Account Password Request"); //} ///// <summary> ///// Change Password ///// </summary> ///// <param name="strStudent"></param> //public void ChangePassword(string strUserID, string strUserName, string Password) //{ // stbEmail = new StringBuilder(); // stbEmail.Append("<table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" >"); // stbEmail.Append("<tr><td><img src=\"http://demo.secureproctor.com/images/logo.png\" />"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>Dear @STUDENTNAME,</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>Our records indicate that you recently reset your password for Secure Vault.</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>This password allows you to log into Secure Proctor.</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>If you did not make this request, please contact us at [email protected] immediately.</td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td> </td></tr>"); // stbEmail.Append("<tr><td>Thanks,</td></tr>"); // stbEmail.Append("<tr><td>Secure Proctor Team.</td></tr>"); // stbEmail.Append("<tr><td>Secure Proctor LLC. ALL RIGHTS RESERVED.</td></tr>"); // stbEmail.Append("<tr><td>Contact Us: [email protected]</td></tr>"); // stbEmail.Append("<tr><td>***<b>DO NOT REPLY TO THIS EMAIL</b>***</td></tr>"); // stbEmail.Append("<tr><td></td></tr></table>"); // BEStudent objBEStudent = new BEStudent(); // BStudent objBStudent = new BStudent(); // objBEStudent.IntUserID = Convert.ToInt32(strUserID); // objBStudent.BGetStudentDetails(objBEStudent); // stbEmail.Replace("@STUDENTNAME", objBEStudent.dtResult.Rows[0]["FirstName"].ToString() + " " + objBEStudent.dtResult.Rows[0]["LastName"].ToString()); // this.SendMail(stbEmail.ToString(), "Secure Proctor: Account Change Password"); //} //#endregion #region Student /// <summary> /// Schedule Exam Mail /// </summary> /// <param name="TransID"></param> public void StudentExamReceipt(Int64 TransID) { stbEmail = new StringBuilder(); stbEmail.Append("<table width=\"100%\" cellpadding=\"0\" cellspacing=\"0\" >"); stbEmail.Append("<tr><td><img src=\"http://demo.secureproctor.com/images/logo.png\" />"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Dear @STUDENTNAME,</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Congratulations! You have successfully registered for the @EXAMNAME.</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Your Exam Information</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>ID : @EXAMID</td></tr>"); stbEmail.Append("<tr><td>Course Name : @COURSENAME</td></tr>"); stbEmail.Append("<tr><td>Exam Name : @EXAMNAME</td></tr>"); stbEmail.Append("<tr><td>Date : @DATE</td></tr>"); stbEmail.Append("<tr><td>Time : @TIME [CST]</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>On the day of your exam please remember to:</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>1. Login into the Examity site 30 minutes prior to the start of the session.</td></tr>"); stbEmail.Append("<tr><td>2. You might have to install some Examity tools.</td></tr>"); stbEmail.Append("<tr><td>3. Bring a valid photo ID (e.g. student ID card, driver's license or passport). This is the same photo ID that was used while setting up the account.</td></tr>"); stbEmail.Append("<tr><td>4. Have your username and password available (you will need this to log into the Exam).</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Scrap paper will be provided to you, including access to a Windows or Mac calculator. To ensure a fair and equal testing experience, personal calculators are not allowed. We encourage you to familiarize yourself with the scientific view of the computer's built-in calculator. Mobile phone, desktop applications (e.g. Excel), and the Internet are also strictly prohibited during the test.</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>We look forward to seeing you soon!</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Good Luck!</td></tr>"); stbEmail.Append("<tr><td> </td></tr>"); stbEmail.Append("<tr><td>Thanks,</td></tr>"); stbEmail.Append("<tr><td>Examity Team.</td></tr>"); stbEmail.Append("<tr><td>Examity LLC. ALL RIGHTS RESERVED.</td></tr>"); stbEmail.Append("<tr><td>Contact Us: [email protected]</td></tr>"); stbEmail.Append("<tr><td>***<b>DO NOT REPLY TO THIS EMAIL</b>***</td></tr>"); stbEmail.Append("<tr><td></td></tr></table>"); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = TransID; objBStudent.BGetStudentExamDetails(objBEStudent); stbEmail.Replace("@EXAMID", TransID.ToString()); stbEmail.Replace("@STUDENTNAME", objBEStudent.DtResult.Rows[0]["Name"].ToString()); stbEmail.Replace("@COURSENAME", objBEStudent.DtResult.Rows[0]["CourseName"].ToString()); stbEmail.Replace("@EXAMNAME", objBEStudent.DtResult.Rows[0]["ExamName"].ToString()); stbEmail.Replace("@DATE", objBEStudent.DtResult.Rows[0]["ExamDate"].ToString()); stbEmail.Replace("@TIME", objBEStudent.DtResult.Rows[0]["TimeDuration"].ToString()); stbEmail.Replace("@URL", "http://test.secureproctor.com/njit/login.aspx"); this.SendMail(stbEmail.ToString(), "Examity: " + objBEStudent.DtResult.Rows[0]["ExamName"].ToString() + " Exam Scheduled Confirmation [" + TransID.ToString() + "]"); this.StudentScheduleMailtoProctor(TransID); }
protected void btnSubmit_Click(object sender, EventArgs e) { BStudent objBStudent = new BStudent(); BEStudent objBEStudent = new BEStudent(); objBEStudent.IntUserID = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID].ToString()); objBEStudent.strAnswer1 = txtAnswer1.Text; objBEStudent.strQuestion1 = hfQid.Value; if (Request.QueryString["TransID"] != null) { objBEStudent.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); } else { Response.Redirect("StartAnExam.aspx"); } // objBEStudent.IntTransID = Convert.ToInt32(HfTransID.Value); objBStudent.BAARandomSecurityQuestionsValidation(objBEStudent); if (objBEStudent.IntResult == 1) { objBEStudent.IntType = 8; objBStudent.BUpdatePLTime(objBEStudent); Response.Redirect("examiKEY.aspx?TransID=" + Request.QueryString["TransID"].ToString(), false); } else { var arr = objBEStudent.StrResult.Split('|'); var x = arr[0]; if (x == "nextQuestion") { hfQid.Value = arr[1].ToString(); lblQuestion1.Text = arr[2].ToString(); lblFailed.Text = ""; txtAnswer1.Text = ""; txtAnswer1.Focus(); } else if (x == "Locked") { Response.Redirect("AuthenticationFailed.aspx?TransID=" + Request.QueryString["TransID"].ToString(), false); } else { lblFailed.Text = x.ToString(); txtAnswer1.Text = ""; txtAnswer1.Focus(); } // lblFailed.Text = objBEStudent.StrResult.ToString(); } }
public string GetSessionID() { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BGetExamSessionID(objBEStudent); return(objBEStudent.strSessionID); }
public string GetExamDetailsByTransID() { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); objBStudent.BGetExamDetailsByTransID(objBEStudent); return(objBEStudent.DtResult.Rows[0]["LockDownBrowser"].ToString()); }
protected void btnProceed_Click(object sender, EventArgs e) { if (Request.QueryString["TransID"] != null) { this.SetFlags("PROCEED", 0); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = Convert.ToInt64(GetTransID()); objBStudent.BUpdateProceedTime(objBEStudent); } }
public void GetEmailID() { BEStudent objbestudent = new BEStudent() { IntUserID = Convert.ToInt32(Session[EnumPageSessions.USERID]) }; BStudent objbstudent = new BStudent(); objbstudent.BGetEmailID(objbestudent); lblMail.Text = lblMail.Text + " " + "<b>" + objbestudent.StrEmail + "</b>" + "."; }
protected void btnProceed_Click(object sender, EventArgs e) { BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = transID; objBEStudent.IntType = 15; objBStudent.BUpdatePLTime(objBEStudent); //Response.Redirect("Authenticationcode.aspx?TransID=" + AppSecurity.Encrypt(transID.ToString()), false); Response.Redirect("ExamiKNOW.aspx?TransID=" + AppSecurity.Encrypt(transID.ToString()), false); }
protected void btnSubmit_Click(object sender, EventArgs e) { Int64 TransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString())); BEStudent objBEStudent = new BEStudent(); BStudent objBStudent = new BStudent(); objBEStudent.IntTransID = TransID;//Convert.ToInt32(AppSecurity.Decrypt(Request.Form["TransID"].ToString())); objBEStudent.IntstatusFlag = 2; objBStudent.BUpdateExamStatus(objBEStudent); Response.Redirect("BeginExamProcess.aspx?TransID=" + Request.QueryString["TransID"].ToString() + "&&ExamiKEY=" + Request.QueryString["examiKEY"].ToString()); }