示例#1
0
        protected void BindDetails()
        {
            try
            {
                BECommon objBECommon = new BECommon();
                BCommon  objBCommon  = new BCommon();
                if (Request.QueryString["TransID"] != null)
                {
                    ViewState[BaseClass.EnumPageSessions.TransID] = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
                    objBCommon.BGetStudentExamDetails(objBECommon);
                    if (objBECommon.DsResult != null && objBECommon.DsResult.Tables[0].Rows.Count > 0)
                    {
                        lblTransactionID.Text = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());
                        lblStudentName.Text   = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                        lblCourseName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                        lblExamName.Text      = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                        lblDAte.Text          = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                        lblSlot.Text          = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                    }
                }
            }

            catch (Exception ex)
            {
                throw ex;
            }
        }
示例#2
0
        protected void BindExamDetails(Int64 TransactionID)
        {
            BECommon objBECommon = new BECommon();
            BCommon  objBCommon  = new BCommon();

            objBECommon.IntTransID = TransactionID;
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);

            if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
            {
                lblStudentName.Text = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                lblCourseName.Text  = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                lblExamName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                lblDAte.Text        = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                lblTime.Text        = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                lblStatus.Text      = objBECommon.DsResult.Tables[0].Rows[0]["StatusName"].ToString();
                if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != string.Empty)
                {
                    lnlFile.Visible = true;
                    lblFile.Visible = false;
                    lnlFile.Text    = objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString();
                }
                else
                {
                    lnlFile.Visible = false;
                    lblFile.Visible = true;
                    lblFile.Text    = "N/A";
                }
            }
        }
 protected void Page_Load(object sender, EventArgs e)
 {
     try
     {
         BECommon objBECommon = new BECommon();
         BCommon  objBCommon  = new BCommon();
         if (Request.QueryString["TransID"] != null)
         {
             this.Page.Title = EnumPageTitles.APPNAME + EnumPageTitles.STUDENT_SCHEDULEDetails;
             //((LinkButton)this.Page.Master.FindControl("lnkReschedule")).CssClass = "main_menu_active";
             objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
             objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
             objBCommon.BGetStudentExamDetails(objBECommon);
             if (objBECommon.DsResult != null)
             {
                 if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                 {
                     lblTransactionID.Text = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());
                     lblStudentName.Text   = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                     lblCourseName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                     lblExamName.Text      = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                     lblDAte.Text          = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                     lblSlot.Text          = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                     //lblHead.Text = "Exam Cancellation Request";
                 }
             }
             lblInfo.Text = "<img src='../Images/yes.png'align='middle'/>&nbsp;<font color='#00C000'>" + "Appointment " + Resources.ResMessages.AppointmentDeleteSuccess + "</font>";
         }
     }
     catch (Exception)
     {
         //ErrorLog.WriteError(Ex);
     }
 }
        protected void BindExamDetails(Int64 TransactionID)
        {
            BECommon objBECommon = new BECommon();
            BCommon  objBCommon  = new BCommon();

            objBECommon.IntTransID = TransactionID;
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);

            if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
            {
                lblTransID.Text     = TransactionID.ToString();
                lblStudentName.Text = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                lblCourseName.Text  = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                lblExamName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                lblDAte.Text        = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                lblTime.Text        = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                lblStatus.Text      = objBECommon.DsResult.Tables[0].Rows[0]["StatusName"].ToString();
                if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != string.Empty)
                {
                    lnlFile.Visible = true;
                    lblFile.Visible = false;
                    lnlFile.Text    = objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString();
                }
                else
                {
                    lnlFile.Visible = false;
                    lblFile.Visible = true;
                    lblFile.Text    = "N/A";
                }
                if (Type == "0")
                {
                    lblInfo.Text = "<img src='../Images/yes.png'align='middle'/>&nbsp;<font color='#00C000'>" + "Appointment scheduled successfully.";
                }
                else if (Type == "1")
                {
                    lblInfo.Text = "<img src='../Images/yes.png'align='middle'/>&nbsp;<font color='#00C000'>" + "Appointment rescheduled successfully.";
                }
                else
                {
                    lblInfo.Text = "<img src='../Images/yes.png'align='middle'/>&nbsp;<font color='#00C000'>" + "Appointment scheduled successfully.";
                }

                if (objBECommon.DsResult.Tables[6] != null)
                {
                    if (objBECommon.DsResult.Tables[6].Rows.Count > 0)
                    {
                        int  leval       = Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"].ToString());
                        bool isexamiFACE = Convert.ToBoolean(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"].ToString());
                        if (leval == 5 || isexamiFACE)
                        {
                            trautoconnect.Visible = true;
                        }
                    }
                }
            }
        }
        protected void lnlFile_Click(Object sender, EventArgs e)
        {
            BECommon objBECommon = new BECommon();
            BCommon  objBCommon  = new BCommon();

            objBECommon.IntTransID = Convert.ToInt64(Session[BaseClass.EnumPageSessions.EXAMID]);
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);

            if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
            {
                if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != string.Empty)
                {
                    string UploadedFile = objBECommon.DsResult.Tables[0].Rows[0]["StoredFileName"].ToString();

                    string MapPath = Server.MapPath(System.Configuration.ConfigurationManager.AppSettings["ProviderUploadPath"].ToString());

                    string fullPath = MapPath + '\\' + UploadedFile;

                    FileInfo fi = new FileInfo(fullPath);

                    if (fi.Exists)
                    {
                        long sz = fi.Length;

                        Response.ClearContent();

                        Response.ContentType = MimeType(Path.GetExtension(fullPath));

                        Response.AddHeader("Content-Disposition", string.Format("attachment; filename = {0}", System.IO.Path.GetFileName(fullPath))); Response.AddHeader("Content-Length", sz.ToString("F0"));

                        Response.TransmitFile(fullPath);

                        Response.End();
                    }
                    else
                    {
                        //ScriptManager.RegisterStartupScript(this, this.GetType(), "NotSaved", "alert('File doesnot exist');", true);

                        Page.ClientScript.RegisterStartupScript(GetType(), "MyScript", "alert('File doesnot exist');", true);
                    }
                }
                else
                {
                    lnlFile.Visible = false;
                    lblFile.Visible = true;
                    lblFile.Text    = "N/A";
                }
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            try
            {
                img.Visible     = false;
                imgBack.Visible = true;
                ((LinkButton)this.Page.Master.FindControl("lnkAutoProctor")).CssClass = "main_menu_active";
                this.Page.Title = EnumPageTitles.APPNAME + EnumPageTitles.AUDITOR_CONFIRMATION;
                BECommon objBECommon = new BECommon();
                BCommon  objBCommon  = new BCommon();
                if (Request.QueryString["TransID"] != null)
                {
                    ViewState[BaseClass.EnumPageSessions.TransID] = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntTransID   = Convert.ToInt32(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntUserID    = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
                    objBECommon.Struserlogin = Session["EmailID"].ToString();
                    objBCommon.BGetStudentExamDetails(objBECommon);
                    if (objBECommon.DsResult.Tables[0] != null)
                    {
                        if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                        {
                            lblTransactionID.Text = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());
                            lblStudentName.Text   = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                            lblcoursename.Text    = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                            lblexamname.Text      = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                            lblDAte.Text          = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                            lblSlot.Text          = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();

                            if (Request.QueryString["type"].ToString() == "1")
                            {
                                lblHead.Text       = "Approved Exam Details";
                                imgConfirm.Visible = true;
                            }


                            else
                            {
                                lblHead.Text = "Rejected Exam Details";
                                //btnReject.Visible = true;
                            }
                        }
                    }
                }
            }
            catch (Exception)
            {
            }
        }
示例#7
0
        protected void lnkFile_Click(object sender, EventArgs e)
        {
            Int64  transID  = Convert.ToInt64(((LinkButton)sender).CommandArgument);
            string FileName = ((LinkButton)sender).Text.ToString();

            BECommon objBECommon = new BECommon();
            BCommon  objBCommon  = new BCommon();

            objBECommon.IntTransID = Convert.ToInt64(transID);
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);

            if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
            {
                if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != string.Empty)
                {
                    string UploadedFile = objBECommon.DsResult.Tables[0].Rows[0]["StoredFileName"].ToString();

                    string MapPath = System.Web.HttpContext.Current.Server.MapPath("../Provider/Provider_Uploads");

                    string fullPath = MapPath + '\\' + UploadedFile;

                    FileInfo fi = new FileInfo(fullPath);

                    if (fi.Exists)
                    {
                        long sz = fi.Length;

                        Response.ClearContent();

                        Response.ContentType = MimeType(Path.GetExtension(fullPath));

                        Response.AddHeader("Content-Disposition", string.Format("attachment; filename = {0}", System.IO.Path.GetFileName(fullPath))); Response.AddHeader("Content-Length", sz.ToString("F0"));

                        Response.TransmitFile(fullPath);

                        Response.End();
                    }
                    else
                    {
                        Page.ClientScript.RegisterStartupScript(GetType(), "MyScript", "alert('File doesnot exist');", true);
                    }
                }
            }
        }
示例#8
0
 protected void BindStudentIdentity()
 {
     try
     {
         BCommon  objBCommon  = new BCommon();
         BECommon objBECommon = new BECommon();
         objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
         objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
         objBCommon.BGetStudentExamDetails(objBECommon);
         if (objBECommon.DsResult != null)
         {
             if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
             {
                 //img.ImageUrl = "../Student/Student_Identity/" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString();
                 img.ImageUrl   = new AppSecurity().ImageToBase64(objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString());
                 img.ImageAlign = ImageAlign.Top;
             }
         }
     }
     catch (Exception)
     {
         //ErrorLog.WriteError(Ex);
     }
 }
示例#9
0
        protected void GetComments()
        {
            Int64    TransactionID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
            BCommon  objBCommon    = new BCommon();
            BECommon objBECommon   = new BECommon();

            objBECommon.IntTransID = TransactionID;
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);
            if (objBECommon.DsResult != null)
            {
                if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                {
                    if (objBECommon.DsResult.Tables[1].Rows.Count > 0)
                    {
                        gvStudentNotes.DataSource = objBECommon.DsResult.Tables[1];
                    }
                    else
                    {
                        gvStudentNotes.DataSource = new object[] { };
                    }
                }
            }
        }
        protected void BindExamDetails()
        {
            try
            {
                BECommon objBECommon = new BECommon();
                BCommon  objBCommon  = new BCommon();
                if (Session[BaseClass.EnumPageSessions.TransID] != null)
                {
                    objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Session[BaseClass.EnumPageSessions.TransID].ToString()));
                    objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
                    objBECommon.DsResult   = new DataSet();
                    objBCommon.BGetStudentExamDetails(objBECommon);
                    if (objBECommon.DsResult != null)
                    {
                        if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                        {
                            gvexamdetails.DataSource = objBECommon.DsResult.Tables[0];
                            if (Convert.ToBoolean(objBECommon.DsResult.Tables[0].Rows[0]["ExamiKey"]) == true)
                            {
                                lblKeyScore.Text        = objBECommon.DsResult.Tables[0].Rows[0]["Examikeyscore"].ToString() + "%";
                                lblKeyScore.Visible     = true;
                                lblKeyScoretext.Visible = true;
                            }
                            else
                            {
                                lblKeyScore.Visible     = false;
                                lblKeyScoretext.Visible = false;
                            }

                            img.ImageUrl   = "~/Student\\Student_Identity\\" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString();
                            img.ImageAlign = ImageAlign.Top;
                        }


                        //if (objBECommon.DsResult.Tables[4].Rows.Count > 0)
                        //{
                        //    lblExamProviderName.Text = objBECommon.DsResult.Tables[4].Rows[0]["ExamProviderName"].ToString();
                        //    lblExamProviderNameEmailAddress.Text = objBECommon.DsResult.Tables[4].Rows[0]["EmailAddress"].ToString();

                        //}

                        if (objBECommon.DsResult.Tables[5].Rows.Count > 0)
                        {
                            lblExamLevel.Text = objBECommon.DsResult.Tables[5].Rows[0]["Level"].ToString();
                        }

                        if (objBECommon.DsResult.Tables[6].Rows.Count > 0)
                        {
                            if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 5 || Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                            {
                                tdDesktop.Visible          = false;
                                trNonProctorImages.Visible = true;
                                trExamLevel.Visible        = false;
                                if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                                {
                                    trVideoPlayer.Visible = true;
                                }
                                else
                                {
                                    trVideoPlayer.Visible = false;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic1TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic1TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic2TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic2TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] != null)
                                {
                                    imgPLExamPic.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic.Src = "~/Images/noimage.jpg";
                                }
                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] != null)
                                {
                                    imgPLExamPic1.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic1.Src = "~/Images/noimage.jpg";
                                }
                            }
                            else
                            {
                                trNonProctorImages.Visible = false;
                                tdDesktop.Visible          = true;
                                trExamLevel.Visible        = true;
                                // trExamiKEY.Visible = false;
                                trVideoPlayer.Visible = true;
                            }
                        }
                    }
                }
                //if (Request.QueryString["Type"] != null)
                //{
                //    btnApprove.Visible = false;
                //    btnReject.Visible = false;
                //}
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
        protected void BindExamDetails()
        {
            try
            {
                BECommon objBECommon = new BECommon();
                BCommon  objBCommon  = new BCommon();

                if (Request.QueryString["TransID"] != null)
                {
                    objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
                    objBCommon.BGetStudentExamDetails(objBECommon);



                    if (objBECommon.DsResult != null)
                    {
                        if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                        {
                            ViewState[BaseClass.EnumPageSessions.TransID] = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());
                            gvexamdetails.DataSource = objBECommon.DsResult.Tables[0];
                            if (Convert.ToBoolean(objBECommon.DsResult.Tables[0].Rows[0]["ExamiKey"]) == true)
                            {
                                lblKeyScore.Text        = objBECommon.DsResult.Tables[0].Rows[0]["Examikeyscore"].ToString() + "%";
                                lblKeyScore.Visible     = true;
                                lblKeyScoretext.Visible = true;
                            }
                            else
                            {
                                lblKeyScore.Visible     = false;
                                lblKeyScoretext.Visible = false;
                            }


                            // string strTotalPath = "~/Student/Student_Identity/" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString();
                            img.ImageUrl = new AppSecurity().ImageToBase64(objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString());
                            //string strTotalPath = Server.MapPath("/Student/Student_Identity/" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString());
                            // if (File.Exists(strTotalPath))
                            //{
                            //    img.ImageUrl = strTotalPath;
                            //}
                            //else
                            //{

                            //    img.ImageUrl = Server.MapPath("~/Student\\Student_Identity\\noimage.jpg");
                            //}


                            // img.ImageUrl = "..\\Student\\Student_Identity\\" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString();
                            // img.ImageUrl = strTotalPath;

                            img.ImageAlign = ImageAlign.Top;

                            //    lblTransactionID.Text = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());

                            //    lblStudentName.Text = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                            //    lblCourseName.Text = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                            //    lblExamName.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                            //    lblDate.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                            //    lblSlot.Text = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                            //    lblExamSatus.Text = objBECommon.DsResult.Tables[0].Rows[0]["StatusName"].ToString();
                            //    lblEmailID.Text = objBECommon.DsResult.Tables[0].Rows[0]["EmailAddress"].ToString();
                            //    lblSpecialNeeds.Text = objBECommon.DsResult.Tables[0].Rows[0]["SpecialNeeds"].ToString();
                            //    if (objBECommon.DsResult.Tables[0].Rows[0]["Comments"] != DBNull.Value && objBECommon.DsResult.Tables[0].Rows[0]["Comments"].ToString() != string.Empty)
                            //    {
                            //        lblComments.Text = objBECommon.DsResult.Tables[0].Rows[0]["Comments"].ToString();
                            //    }
                            //    else
                            //    {
                            //        lblComments.Text = "N/A";
                            //    }

                            //    lblMaxAttempts.Text = objBECommon.DsResult.Tables[0].Rows[0]["AllowedAttempts"].ToString();
                            //    lblUsedAttempts.Text = objBECommon.DsResult.Tables[0].Rows[0]["UsedAttempts"].ToString();
                        }


                        if (objBECommon.DsResult.Tables[5].Rows.Count > 0)
                        {
                            lblExamLevel.Text = objBECommon.DsResult.Tables[5].Rows[0]["Level"].ToString();
                        }

                        if (objBECommon.DsResult.Tables[6].Rows.Count > 0)
                        {
                            //If exam security is auto-standard, hide Comments , Added By , Added On columns. Github #197
                            if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 6)
                            {
                                hideCommentGridColumnsForAutoStandard();
                            }


                            if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 5 || Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                            {
                                tdDesktop.Visible          = false;
                                trNonProctorImages.Visible = true;
                                trExamLevel.Visible        = false;
                                if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                                {
                                    if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 2)
                                    {
                                        // if (new CommonFunctions().GetVideoVisibleStatus(Convert.ToInt64(AppSecurity.Decrypt(Session[BaseClass.EnumPageSessions.TransID].ToString()))))
                                        trVideoPlayer.Visible = true;
                                    }

                                    else
                                    {
                                        trVideoPlayer.Visible = false;
                                    }
                                }
                                else
                                {
                                    trVideoPlayer.Visible = false;
                                }
                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic1TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic1TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic2TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic2TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] != null)
                                {
                                    imgPLExamPic.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic.Src = "~/Images/noimage.jpg";
                                }
                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] != null)
                                {
                                    imgPLExamPic1.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic1.Src = "~/Images/noimage.jpg";
                                }
                            }
                            else
                            {
                                trNonProctorImages.Visible = false;
                                tdDesktop.Visible          = true;
                                trExamLevel.Visible        = true;
                                trVideoPlayer.Visible      = true;
                            }
                            //if (objBECommon.DsResult.Tables[6].Rows[0][0] != null && objBECommon.DsResult.Tables[6].Rows[0][1] != null)
                            //{
                            //    //System.Drawing.Image image1= getImage(objBECommon.DsResult.Tables[6].Rows[0][0]  as byte[]);
                            //    //System.Drawing.Image image2 = getImage(objBECommon.DsResult.Tables[6].Rows[0][1] as byte[]);
                            //    trNonProctorImages.Visible = true;
                            //    //imgpic1.ImageUrl = image1.ToString();
                            //    //imgpic2.ImageUrl = image2.ToString();

                            //    imgPLExamPic.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0][0] as byte[]);
                            //    imgPLExamPic1.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0][1] as byte[]);
                            //    tdDesktop.Visible = false;

                            //}
                            //else
                            //{
                            //    trNonProctorImages.Visible = false;
                            //    tdDesktop.Visible = true;
                            //}
                        }
                    }
                }
                //if (Request.QueryString["Type"] != null)
                //{
                //    btnApprove.Visible = false;
                //    btnReject.Visible = false;
                //}
            }
            catch (Exception Ex)
            {
                throw Ex;
            }
        }
        protected void BindExamDetails()
        {
            try
            {
                BECommon objBECommon = new BECommon();
                BCommon  objBCommon  = new BCommon();

                if (Request.QueryString["TransID"] != null)
                {
                    objBECommon.IntTransID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
                    objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
                    objBCommon.BGetStudentExamDetails(objBECommon);
                    if (objBECommon.DsResult != null)
                    {
                        if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                        {
                            ViewState[BaseClass.EnumPageSessions.TransID] = AppSecurity.Decrypt(Request.QueryString["TransID"].ToString());
                            gvexamdetails.DataSource = objBECommon.DsResult.Tables[0];
                            if (Convert.ToBoolean(objBECommon.DsResult.Tables[0].Rows[0]["ExamiKey"]) == true)
                            {
                                lblKeyScore.Text        = objBECommon.DsResult.Tables[0].Rows[0]["Examikeyscore"].ToString() + "%";
                                lblKeyScore.Visible     = true;
                                lblKeyScoretext.Visible = true;
                            }
                            else
                            {
                                lblKeyScore.Visible     = false;
                                lblKeyScoretext.Visible = false;
                            }
                            //img.ImageUrl = "~/Student/Student_Identity/" + objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString();
                            img.ImageUrl   = new AppSecurity().ImageToBase64(objBECommon.DsResult.Tables[0].Rows[0]["PhotoIdentity"].ToString().Substring(3).ToString());
                            img.ImageAlign = ImageAlign.Top;
                        }


                        if (objBECommon.DsResult.Tables[5].Rows.Count > 0)
                        {
                            lblExamLevel.Text = objBECommon.DsResult.Tables[5].Rows[0]["Level"].ToString();
                        }

                        if (objBECommon.DsResult.Tables[6].Rows.Count > 0)
                        {
                            //If exam security is auto-standard, hide Comments , Added By , Added On columns. Github #197
                            if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 6)
                            {
                                hideCommentGridColumnsForAutoStandard();
                            }

                            if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 5 || Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                            {
                                tdDesktop.Visible          = false;
                                trNonProctorImages.Visible = true;
                                trExamLevel.Visible        = false;

                                if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["IsexamiFACE"]) == 1)
                                {
                                    if (Convert.ToInt32(objBECommon.DsResult.Tables[6].Rows[0]["secirtyType"]) == 2)
                                    {
                                        // if (new CommonFunctions().GetVideoVisibleStatus(Convert.ToInt64(AppSecurity.Decrypt(Session[BaseClass.EnumPageSessions.TransID].ToString()))))
                                        trVideoPlayer.Visible = true;
                                    }

                                    else
                                    {
                                        trVideoPlayer.Visible = false;
                                    }
                                }
                                else
                                {
                                    trVideoPlayer.Visible = false;
                                }
                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic1TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic1TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"] != DBNull.Value)
                                {
                                    lblPic2TimeStamp.Text = objBECommon.DsResult.Tables[6].Rows[0]["studentIDImageTimeStamp"].ToString();
                                }
                                else
                                {
                                    lblPic2TimeStamp.Text = string.Empty;
                                }

                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] != null)
                                {
                                    imgPLExamPic.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic.Src = "/Images/noimage.jpg";
                                }
                                if (objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"].ToString() != "" && objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] != null)
                                {
                                    imgPLExamPic1.Src = "data:image/png;base64," + Convert.ToBase64String(objBECommon.DsResult.Tables[6].Rows[0]["StudentIDImage"] as byte[]);
                                }
                                else
                                {
                                    imgPLExamPic1.Src = "/Images/noimage.jpg";
                                }
                            }
                            else
                            {
                                trNonProctorImages.Visible = false;
                                tdDesktop.Visible          = true;
                                trExamLevel.Visible        = true;
                                trVideoPlayer.Visible      = true;
                            }
                        }
                    }
                }
            }
            catch (Exception Ex)
            {
                throw Ex;
            }
        }
示例#13
0
        protected void setExamDetails()
        {
            Int64    TransactionID = Convert.ToInt64(AppSecurity.Decrypt(Request.QueryString["TransID"].ToString()));
            BCommon  objBCommon    = new BCommon();
            BECommon objBECommon   = new BECommon();

            objBECommon.IntTransID = TransactionID;
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);
            if (objBECommon.DsResult != null)
            {
                if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
                {
                    lblTransactionID.Text = objBECommon.IntTransID.ToString();
                    lblDAte.Text          = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                    //lblSlot.Text = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                    lblSlot.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamStartDate"].ToString();
                    // lblStudentName.Text = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                    //lblEmailID.Text = objBECommon.DsResult.Tables[0].Rows[0]["EmailAddress"].ToString();
                    lblCourseName.Text  = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                    lblExamName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                    lblPhoneNumber.Text = CommonFunctions.CheckNullValue(objBECommon.DsResult.Tables[0].Rows[0]["PhoneNumber"].ToString());
                    // lblTimeZone.Text = objBECommon.DsResult.Tables[0].Rows[0]["TimeZone"].ToString();
                    lblSpecialNeeds.Text = objBECommon.DsResult.Tables[0].Rows[0]["SpecialNeeds"].ToString();
                    lblExamLink.Text     = objBECommon.DsResult.Tables[0].Rows[0]["ExamLink"].ToString();
                    if (objBECommon.DsResult.Tables[0].Rows[0]["Comments"] != DBNull.Value && objBECommon.DsResult.Tables[0].Rows[0]["Comments"].ToString() != string.Empty)
                    {
                        lblComments.Text = objBECommon.DsResult.Tables[0].Rows[0]["Comments"].ToString();
                    }
                    else
                    {
                        lblComments.Text = "N/A";
                    }

                    lblDuration.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamDuration"].ToString();
                    //lblEndTime.Text = objBECommon.DsResult.Tables[0].Rows[0]["EndTime"].ToString();
                    lblEndTime.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamEndDate"].ToString();

                    if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != "")
                    {
                        lnkProviderFile.Visible = true;
                        lnkProviderFile.Text    = objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString();
                        lblError.Visible        = false;
                        if (objBECommon.DsResult.Tables[0].Rows[0]["StoredFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["StoredFileName"].ToString() != "")
                        {
                            string UploadedFile = objBECommon.DsResult.Tables[0].Rows[0]["StoredFileName"].ToString();

                            string MapPath = System.Web.HttpContext.Current.Server.MapPath("../Provider/Provider_Uploads");

                            string fullPath = MapPath + '\\' + UploadedFile;

                            FileInfo fi = new FileInfo(fullPath);

                            if (!fi.Exists)
                            {
                                lnkProviderFile.Visible = false;
                                lblError.Visible        = true;
                                lblError.Text           = "File doesnot exists";
                                lblError.ForeColor      = System.Drawing.Color.Red;
                            }
                        }
                    }
                    else
                    {
                        lnkProviderFile.Visible = false;
                        lblError.Visible        = true;
                        lblError.Text           = "N/A";
                    }
                }
            }

            bool noTools = false;

            if (objBECommon.DsResult.Tables[2].Rows.Count > 0)
            {
                noTools = true;
                for (int i = 0; i < objBECommon.DsResult.Tables[2].Rows.Count; i++)
                {
                    if (objBECommon.DsResult.Tables[2].Rows[i]["ToolID"].ToString() == "101")
                    {
                        imgCalc.Visible = true;
                    }
                    if (objBECommon.DsResult.Tables[2].Rows[i]["ToolID"].ToString() == "102")
                    {
                        imgStickyNotes.Visible = true;
                    }
                }
            }
            if (noTools == false)
            {
                lblTools.Visible = true;
            }

            if (objBECommon.DsResult.Tables[4].Rows.Count > 0)
            {
                lblExamProviderName.Text         = objBECommon.DsResult.Tables[4].Rows[0]["ExamProviderName"].ToString();
                lblExamProviderEmailAddress.Text = objBECommon.DsResult.Tables[4].Rows[0]["EmailAddress"].ToString();
            }
        }
示例#14
0
        protected void SetExamDetails(Int64 TransactionID)
        {
            BECommon objBECommon = new BECommon();
            BCommon  objBCommon  = new BCommon();

            objBECommon.IntTransID = TransactionID;
            objBECommon.IntUserID  = Convert.ToInt32(Session[BaseClass.EnumPageSessions.USERID]);
            objBCommon.BGetStudentExamDetails(objBECommon);

            if (objBECommon.DsResult.Tables[0].Rows.Count > 0)
            {
                lblTransactionID.Text = objBECommon.IntTransID.ToString();
                lblStudentName.Text   = objBECommon.DsResult.Tables[0].Rows[0]["Name"].ToString();
                lblCourseName.Text    = objBECommon.DsResult.Tables[0].Rows[0]["CourseName"].ToString();
                //lblExamName.Text = objBECommon.DsResult.Tables[0].Rows[0]["ExamName"].ToString();
                lblDAte.Text   = objBECommon.DsResult.Tables[0].Rows[0]["ExamDate"].ToString();
                lblSlot.Text   = objBECommon.DsResult.Tables[0].Rows[0]["TimeDuration"].ToString();
                lblStatus.Text = objBECommon.DsResult.Tables[0].Rows[0]["StatusName"].ToString();
                if (objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"] != null && objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString() != string.Empty)
                {
                    lnlFile.Visible = true;
                    lblFile.Visible = false;
                    lnlFile.Text    = objBECommon.DsResult.Tables[0].Rows[0]["OriginalFileName"].ToString();
                }
                else
                {
                    lnlFile.Visible = false;
                    lblFile.Visible = true;
                    lblFile.Text    = "N/A";
                }
            }



            if (objBECommon.DsResult.Tables[3].Rows.Count > 0)
            {
                // gvStudentRules.Visible = true;
                // gvStudentRules.DataSource = objBECommon.DsResult.Tables[3];

                //gvStudentRules.DataBind();
            }
            else
            {
                // gvStudentRules.Visible = false;
            }
            //else
            //   {
            // gvStudentRules.DataSource = null;

            //   gvStudentRules.DataSource = new object[] { };

            // gvStudentRules.DataBind();

            // }



            bool noTools = false;

            if (objBECommon.DsResult.Tables[2].Rows.Count > 0)
            {
                noTools = true;
                for (int i = 0; i < objBECommon.DsResult.Tables[2].Rows.Count; i++)
                {
                    if (objBECommon.DsResult.Tables[2].Rows[i]["ToolID"].ToString() == "101")
                    {
                        imgCalc.Visible = true;
                    }
                    if (objBECommon.DsResult.Tables[2].Rows[i]["ToolID"].ToString() == "102")
                    {
                        imgStickyNotes.Visible = true;
                    }
                }
            }
            if (noTools == false)
            {
                lblError.Visible = true;
                lblError.Text    = "N/A";
            }
        }