Exemple #1
0
 public void eventActivation(int event_id, XUISwitch switchIsActivated, Label lblSwitchStatus)
 {
     if (switchIsActivated.SwitchState == XUISwitch.State.On)
     {
         _event.eventActivation(event_id, 1);
         lblSwitchStatus.Text = "Activated";
     }
     else
     {
         _event.eventActivation(event_id, 0);
         lblSwitchStatus.Text = "Activated";
     }
 }
 public void studentActivation(string currentID, XUISwitch switchIsActivated, Label lblSwitchStatus)
 {
     if (switchIsActivated.SwitchState == XUISwitch.State.On)
     {
         _student.studentActivation(currentID, 1);
         lblSwitchStatus.Text = "Activated";
     }
     else
     {
         _student.studentActivation(currentID, 0);
         lblSwitchStatus.Text = "Deactivated";
     }
 }
Exemple #3
0
 public void guestActivation(int currentID, XUISwitch switchIsActivated, Label lblSwitchStatus)
 {
     if (switchIsActivated.SwitchState == XUISwitch.State.On)
     {
         _guest.guestActivation(currentID, 1);
         lblSwitchStatus.Text = "Activated";
     }
     else
     {
         _guest.guestActivation(currentID, 0);
         lblSwitchStatus.Text = "Deactivated";
     }
 }
Exemple #4
0
 public void prepareGuest(int currentID, RadioButton rbnstudent, RadioButton rbnWorking, TextBox txtFirstName,
                          TextBox txtMiddleName, TextBox txtLastName, TextBox txtAddress, TextBox txtContact, TextBox txtEmail,
                          RadioButton rbnMale, RadioButton rbnFemale, TextBox txtSchoolName, TextBox txtCourse, TextBox txtYear,
                          TextBox txtWorksAt, TextBox txtPosition, XUISwitch switchIsActivated, Label lblSwitchStatus, ComboBox cmbEvents)
 {
     _guest.selectGuest(currentID);
     txtFirstName.Text  = _guest.getGuestData("first_name");
     txtMiddleName.Text = _guest.getGuestData("middle_name");
     txtLastName.Text   = _guest.getGuestData("last_name");
     txtAddress.Text    = _guest.getGuestData("address");
     txtContact.Text    = _guest.getGuestData("contact");
     txtEmail.Text      = _guest.getGuestData("email");
     if (_guest.getGuestData("gender") == "M")
     {
         rbnMale.Checked = true;
     }
     else
     {
         rbnFemale.Checked = true;
     }
     if (!String.IsNullOrEmpty(_guest.getGuestData("school_name")))
     {
         rbnstudent.Checked = true;
     }
     else
     {
         rbnWorking.Checked = true;
     }
     txtSchoolName.Text = _guest.getGuestData("school_name");
     txtCourse.Text     = _guest.getGuestData("course");
     txtYear.Text       = _guest.getGuestData("year");
     txtWorksAt.Text    = _guest.getGuestData("works_at");
     txtPosition.Text   = _guest.getGuestData("position");
     if (bool.Parse(_guest.getGuestData("is_activated")) == true)
     {
         switchIsActivated.SwitchState = XUISwitch.State.On;
         lblSwitchStatus.Text          = "Activated";
     }
     else
     {
         switchIsActivated.SwitchState = XUISwitch.State.Off;
         lblSwitchStatus.Text          = "Deactivated";
     }
     cmbEvents.SelectedIndex = cmbEvents.FindStringExact(_guest.getGuestData("event_name"));
 }
Exemple #5
0
 public void prepareEvent(int event_id, TextBox txtEventName, TextBox txtVenue, DateTimePicker dateFrom,
                          DateTimePicker dateTo, DateTimePicker timeFrom, DateTimePicker timeTo, TextBox txtStudentRegistration, TextBox txtStudentSlots,
                          TextBox txtEventDetails, CheckBox chkGuests, TextBox txtGuestRegistration, TextBox txtGuestSlots,
                          XUISwitch switchIsActivated, Label lblSwitchStatus)
 {
     _event.selectEvent(event_id);
     txtEventName.Text = _event.getEventData("event_name");
     txtVenue.Text     = _event.getEventData("venue");
     dateFrom.Value    = Convert.ToDateTime(_event.getEventData("date_from"));
     dateTo.Value      = Convert.ToDateTime(_event.getEventData("date_to"));
     string[] times = _event.getEventData("time").Split(new string[] { " - " }, StringSplitOptions.None);
     timeFrom.Value = Convert.ToDateTime(times[0]);
     timeTo.Value   = Convert.ToDateTime(times[1]);
     txtStudentRegistration.Text = _event.getEventData("student_registration");
     txtStudentSlots.Text        = _event.getEventData("student_slots");
     txtEventDetails.Text        = _event.getEventData("event_details");
     if (bool.Parse(_event.getEventData("allow_guests")) == true)
     {
         chkGuests.Checked         = true;
         txtGuestRegistration.Text = _event.getEventData("guest_registration");
         txtGuestSlots.Text        = _event.getEventData("guest_slots");
     }
     else
     {
         chkGuests.Checked = false;
     }
     if (bool.Parse(_event.getEventData("is_activated")) == true)
     {
         switchIsActivated.SwitchState = XUISwitch.State.On;
         lblSwitchStatus.Text          = "Activated";
     }
     else
     {
         switchIsActivated.SwitchState = XUISwitch.State.Off;
         lblSwitchStatus.Text          = "Deactivated";
     }
 }
 public void prepareStudent(string currentID, TextBox txtFirstName, TextBox txtMiddleName, TextBox txtLastName,
                            TextBox txtAddress, TextBox txtContact, TextBox txtEmailAddress, RadioButton rbnMale, RadioButton rbnFemale,
                            TextBox txtIDNo, TextBox txtCourse, TextBox txtYearAndSection, XUISwitch switchIsActivated, Label lblSwitchStatus)
 {
     _student.selectStudent(currentID);
     txtIDNo.Text         = _student.getStudentData("id");
     txtFirstName.Text    = _student.getStudentData("first_name");
     txtMiddleName.Text   = _student.getStudentData("middle_name");
     txtLastName.Text     = _student.getStudentData("last_name");
     txtAddress.Text      = _student.getStudentData("address");
     txtContact.Text      = _student.getStudentData("contact");
     txtEmailAddress.Text = _student.getStudentData("email");
     if (_student.getStudentData("gender") == "M")
     {
         rbnMale.Checked = true;
     }
     else
     {
         rbnFemale.Checked = false;
     }
     txtCourse.Text         = _student.getStudentData("course");
     txtYearAndSection.Text = _student.getStudentData("year_and_section");
     if (bool.Parse(_student.getStudentData("is_activated")) == true)
     {
         switchIsActivated.SwitchState = XUISwitch.State.On;
         lblSwitchStatus.Text          = "Activated";
     }
     else
     {
         switchIsActivated.SwitchState = XUISwitch.State.Off;
         lblSwitchStatus.Text          = "Deactivated";
     }
 }
Exemple #7
0
        public void setGuestRequests()
        {
            foreach (var guestId in listGuestId)
            {
                _guest.selectGuest(int.Parse(guestId));

                Label lblEventName = new Label();
                lblEventName.AutoSize = true;
                lblEventName.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblEventName.Location = new Point(9, 5);
                lblEventName.Name     = "lblEventName";
                lblEventName.Size     = new Size(41, 15);
                lblEventName.Text     = "Event: " + _guest.getGuestData("event_name");

                Label lblFullName = new Label();
                lblFullName.AutoSize = true;
                lblFullName.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblFullName.Location = new Point(9, 25);
                lblFullName.Name     = "lblFullName";
                lblFullName.Size     = new Size(68, 15);
                lblFullName.Text     = "Full Name: " + _guest.getGuestData("first_name") + " " +
                                       _guest.getGuestData("middle_name") + " " + _guest.getGuestData("last_name");

                Label lblGender = new Label();
                lblGender.AutoSize = true;
                lblGender.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblGender.Location = new Point(9, 45);
                lblGender.Name     = "lblGender";
                lblGender.Size     = new Size(57, 15);
                if (_guest.getGuestData("gender") == "M")
                {
                    lblGender.Text = "Gender: Male";
                }
                else
                {
                    lblGender.Text = "Gender: Female";
                }

                Label lblAddress = new Label();
                lblAddress.AutoSize = true;
                lblAddress.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblAddress.Location = new Point(8, 65);
                lblAddress.Name     = "lblAddress";
                lblAddress.Size     = new Size(51, 15);
                lblAddress.Text     = "Address: " + _guest.getGuestData("address");

                Label lblContactNo = new Label();
                lblContactNo.AutoSize = true;
                lblContactNo.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblContactNo.Location = new Point(9, 85);
                lblContactNo.Name     = "lblContactNo";
                lblContactNo.Size     = new Size(103, 15);
                lblContactNo.Text     = "Contact Number: " + _guest.getGuestData("contact");

                Label lblEmailAddress = new Label();
                lblEmailAddress.AutoSize = true;
                lblEmailAddress.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblEmailAddress.Location = new Point(9, 105);
                lblEmailAddress.Name     = "lblEmailAddress";
                lblEmailAddress.Size     = new Size(92, 15);
                lblEmailAddress.Text     = "Email Address: " + _guest.getGuestData("email");

                Label lblInfo1 = new Label();
                lblInfo1.AutoSize = true;
                lblInfo1.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblInfo1.Location = new Point(8, 125);
                lblInfo1.Name     = "lblInfo1";
                lblInfo1.Size     = new Size(38, 15);

                Label lblInfo2 = new Label();
                lblInfo2.AutoSize = true;
                lblInfo2.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblInfo2.Location = new Point(8, 145);
                lblInfo2.Name     = "lblInfo2";
                lblInfo2.Size     = new Size(38, 15);
                if (!String.IsNullOrEmpty(_guest.getGuestData("school_name")))
                {
                    lblInfo1.Text = "School Name: " + _guest.getGuestData("school_name");
                    lblInfo2.Text = "Course & Year: " + _guest.getGuestData("course") + " - " +
                                    _guest.getGuestData("year");
                }
                else
                {
                    lblInfo1.Text = "Works at: " + _guest.getGuestData("works_at");
                    lblInfo2.Text = "Position: " + _guest.getGuestData("position");
                }

                Label lblSwitchStatus = new Label();
                lblSwitchStatus.AutoSize = true;
                lblSwitchStatus.Font     = new Font("Roboto", 9F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(0)));
                lblSwitchStatus.Location = new Point(369, 20);
                lblSwitchStatus.Name     = "lblSwitchStatus";
                lblSwitchStatus.Size     = new Size(69, 14);
                lblSwitchStatus.Text     = "Deactivated";

                XUISwitch switchIsActivated = new XUISwitch();
                switchIsActivated.BackColor      = Color.Transparent;
                switchIsActivated.HandleOffColor = Color.FromArgb(((int)(((byte)(230)))), ((int)(((byte)(71)))), ((int)(((byte)(89)))));
                switchIsActivated.HandleOnColor  = Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(178)))), ((int)(((byte)(255)))));
                switchIsActivated.Location       = new Point(303, 12);
                switchIsActivated.Name           = "switchIsActivated";
                switchIsActivated.OffColor       = Color.FromArgb(((int)(((byte)(234)))), ((int)(((byte)(129)))), ((int)(((byte)(136)))));
                switchIsActivated.OnColor        = Color.FromArgb(((int)(((byte)(102)))), ((int)(((byte)(204)))), ((int)(((byte)(255)))));
                switchIsActivated.Size           = new Size(60, 28);
                switchIsActivated.SwitchState    = XanderUI.XUISwitch.State.Off;
                switchIsActivated.SwitchStyle    = XanderUI.XUISwitch.Style.Horizontal;
                switchIsActivated.Text           = "xuiSwitch1";
                switchIsActivated.Click         += (s, e) => {
                    Guest g1 = new Guest();
                    if (switchIsActivated.SwitchState == XUISwitch.State.Off)
                    {
                        g1.guestActivation(int.Parse(guestId), 0);
                        lblSwitchStatus.Text = "Deactivated";
                        g1.guestActivation(int.Parse(guestId), 1);
                        _eventDetails.removeGuestParticipant(int.Parse(guestId));
                    }
                    else
                    {
                        g1.guestActivation(int.Parse(guestId), 1);
                        _event.selectEventByName(_guest.getGuestData("event_name"));
                        int event_id = int.Parse(_event.getEventData("id"));
                        registerGuest(event_id, int.Parse(guestId));
                        lblSwitchStatus.Text = "Activated";
                    }
                };

                Panel panelGuest = new Panel();
                panelGuest.Controls.Add(lblSwitchStatus);
                panelGuest.Controls.Add(lblEventName);
                panelGuest.Controls.Add(switchIsActivated);
                panelGuest.Controls.Add(lblInfo1);
                panelGuest.Controls.Add(lblInfo2);
                panelGuest.Controls.Add(lblAddress);
                panelGuest.Controls.Add(lblEmailAddress);
                panelGuest.Controls.Add(lblContactNo);
                panelGuest.Controls.Add(lblFullName);
                panelGuest.Controls.Add(lblGender);
                panelGuest.Location    = new Point(3, 3);
                panelGuest.Name        = "panelGuest";
                panelGuest.BorderStyle = BorderStyle.FixedSingle;
                panelGuest.Size        = new Size(458, 166);

                th.setLabelColor(lblEventName);
                th.setLabelColor(lblFullName);
                th.setLabelColor(lblGender);
                th.setLabelColor(lblAddress);
                th.setLabelColor(lblContactNo);
                th.setLabelColor(lblEmailAddress);
                th.setLabelColor(lblInfo1);
                th.setLabelColor(lblInfo2);
                th.setLabelColor(lblSwitchStatus);

                flowLayoutGuest.Controls.Add(panelGuest);
            }
        }
Exemple #8
0
        public void setEventRequests()
        {
            foreach (var eventId in listEventIds)
            {
                _event.selectEvent(int.Parse(eventId));
                Label lblVenue = new Label();
                lblVenue.AutoSize = true;
                lblVenue.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblVenue.Location = new Point(6, 19);
                lblVenue.Name     = "lblVenue";
                lblVenue.Size     = new Size(46, 15);
                lblVenue.Text     = "Venue: " + _event.getEventData("venue");


                Label lblDate = new Label();
                lblDate.AutoSize = true;
                lblDate.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblDate.Location = new Point(6, 39);
                lblDate.Name     = "lblDate";
                lblDate.Size     = new Size(37, 15);
                lblDate.Text     = "Date: " + _event.getEventData("date_from") + " - " + _event.getEventData("date_to");

                Label lblTime = new Label();
                lblTime.AutoSize = true;
                lblTime.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblTime.Location = new Point(6, 59);
                lblTime.Name     = "lblTime";
                lblTime.Size     = new Size(40, 15);
                lblTime.Text     = "Time: " + _event.getEventData("time");

                Label lblStudentRegistrationFee = new Label();
                lblStudentRegistrationFee.AutoSize = true;
                lblStudentRegistrationFee.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblStudentRegistrationFee.Location = new Point(6, 99);
                lblStudentRegistrationFee.Name     = "lblStudentRegistrationFee";
                lblStudentRegistrationFee.Size     = new Size(149, 15);
                if (_event.getEventData("student_registration") != "0")
                {
                    lblStudentRegistrationFee.Text = "Student Registration Fee: Php " +
                                                     _event.getEventData("student_registration");
                }
                else
                {
                    lblStudentRegistrationFee.Text = "Student Registration Fee: Free";
                }

                Label lblStudentSlots = new Label();
                lblStudentSlots.AutoSize = true;
                lblStudentSlots.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblStudentSlots.Location = new Point(6, 79);
                lblStudentSlots.Name     = "lblStudentSlots";
                lblStudentSlots.Size     = new Size(86, 15);
                if (_event.getEventData("student_slots") != "0")
                {
                    lblStudentSlots.Text = "Student Slots: " + _event.getEventData("student_slots");
                }
                else
                {
                    lblStudentSlots.Text = "Student Slots: Open";
                }

                Label lblGuestRegistrationFee = new Label();
                lblGuestRegistrationFee.AutoSize = true;
                lblGuestRegistrationFee.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblGuestRegistrationFee.Location = new Point(6, 139);
                lblGuestRegistrationFee.Name     = "lblGuestRegistrationFee";
                lblGuestRegistrationFee.Size     = new Size(139, 15);

                Label lblGuestSlots = new Label();
                lblGuestSlots.AutoSize = true;
                lblGuestSlots.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblGuestSlots.Location = new Point(6, 119);
                lblGuestSlots.Name     = "lblGuestSlots";
                lblGuestSlots.Size     = new Size(76, 15);


                if (_event.getEventData("allow_guests") != "0")
                {
                    if (_event.getEventData("guest_registration") != "0")
                    {
                        lblGuestRegistrationFee.Text = "Guest Registration Fee: Php " +
                                                       _event.getEventData("guest_registration");
                    }
                    else
                    {
                        lblGuestRegistrationFee.Text = "Guest Registration Fee: Free";
                    }
                    if (_event.getEventData("guest_slots") != "0")
                    {
                        lblGuestSlots.Text = "Guest Slots: " + _event.getEventData("guest_slots");
                    }
                    else
                    {
                        lblGuestSlots.Text = "Guest Slots: Open";
                    }
                }
                else
                {
                    lblGuestRegistrationFee.Text = "N/A";
                    lblGuestSlots.Text           = "N/A";
                }

                Label lblEventDetails = new Label();
                lblEventDetails.AutoSize = true;
                lblEventDetails.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblEventDetails.Location = new Point(313, 34);
                lblEventDetails.Name     = "lblEventDetails";
                lblEventDetails.Size     = new Size(81, 15);
                lblEventDetails.Text     = "Event Details";

                TextBox txtEventDetails = new TextBox();
                txtEventDetails.BackColor = Color.White;
                txtEventDetails.Font      = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                txtEventDetails.Location  = new Point(316, 52);
                txtEventDetails.Multiline = true;
                txtEventDetails.Name      = "txtEventDetails";
                txtEventDetails.ReadOnly  = true;
                txtEventDetails.Size      = new Size(302, 102);
                txtEventDetails.Text      = _event.getEventData("event_details");

                Label lblSwitchStatus = new Label();
                lblSwitchStatus.AutoSize = true;
                lblSwitchStatus.Font     = new Font("Roboto", 9F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(0)));
                lblSwitchStatus.Location = new Point(549, 34);
                lblSwitchStatus.Name     = "lblSwitchStatus";
                lblSwitchStatus.Size     = new Size(69, 14);
                lblSwitchStatus.Text     = "Deactivated";

                XUISwitch switchIsActivated = new XUISwitch();
                switchIsActivated.BackColor      = Color.Transparent;
                switchIsActivated.HandleOffColor = Color.FromArgb(((int)(((byte)(230)))), ((int)(((byte)(71)))), ((int)(((byte)(89)))));
                switchIsActivated.HandleOnColor  = Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(178)))), ((int)(((byte)(255)))));
                switchIsActivated.Location       = new Point(483, 24);
                switchIsActivated.Name           = "switchIsActivated";
                switchIsActivated.OffColor       = Color.FromArgb(((int)(((byte)(234)))), ((int)(((byte)(129)))), ((int)(((byte)(136)))));
                switchIsActivated.OnColor        = Color.FromArgb(((int)(((byte)(102)))), ((int)(((byte)(204)))), ((int)(((byte)(255)))));
                switchIsActivated.Size           = new Size(60, 28);
                switchIsActivated.SwitchState    = XUISwitch.State.Off;
                switchIsActivated.SwitchStyle    = XUISwitch.Style.Horizontal;
                switchIsActivated.Text           = "xuiSwitch1";
                switchIsActivated.Click         += (s, e) => {
                    Event e1 = new Event();
                    if (switchIsActivated.SwitchState == XUISwitch.State.Off)
                    {
                        e1.eventActivation(int.Parse(eventId), 0);
                        lblSwitchStatus.Text = "Deactivated";
                    }
                    else
                    {
                        e1.eventActivation(int.Parse(eventId), 1);
                        lblSwitchStatus.Text = "Activated";
                    }
                };

                GroupBox groupEvent = new GroupBox();
                groupEvent.Controls.Add(lblSwitchStatus);
                groupEvent.Controls.Add(txtEventDetails);
                groupEvent.Controls.Add(switchIsActivated);
                groupEvent.Controls.Add(lblEventDetails);
                groupEvent.Controls.Add(lblGuestSlots);
                groupEvent.Controls.Add(lblGuestRegistrationFee);
                groupEvent.Controls.Add(lblStudentSlots);
                groupEvent.Controls.Add(lblStudentRegistrationFee);
                groupEvent.Controls.Add(lblTime);
                groupEvent.Controls.Add(lblDate);
                groupEvent.Controls.Add(lblVenue);
                groupEvent.Font     = new Font("Roboto", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                groupEvent.Location = new Point(3, 3);
                groupEvent.Name     = "groupEvent";
                groupEvent.Size     = new Size(629, 170);
                groupEvent.TabStop  = false;
                groupEvent.Text     = _event.getEventData("event_name");

                th.setLabelColor(lblVenue);
                th.setLabelColor(lblDate);
                th.setLabelColor(lblTime);
                th.setLabelColor(lblStudentRegistrationFee);
                th.setLabelColor(lblStudentSlots);
                th.setLabelColor(lblGuestRegistrationFee);
                th.setLabelColor(lblGuestSlots);
                th.setLabelColor(lblEventDetails);
                th.setLabelColor(lblSwitchStatus);
                th.setGroupBoxColor(groupEvent);

                flowLayoutEvent.Controls.Add(groupEvent);
            }
        }
Exemple #9
0
        public void setStudentRequests()
        {
            foreach (var studentId in listStudentId)
            {
                Label lblStudentIDNo = new Label();
                lblStudentIDNo.AutoSize = true;
                lblStudentIDNo.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblStudentIDNo.Location = new Point(9, 5);
                lblStudentIDNo.Name     = "lblStudentIDNo";
                lblStudentIDNo.Size     = new Size(41, 15);
                lblStudentIDNo.Text     = "ID No.: " + _student.getStudentData("id");

                Label lblFullName = new Label();
                lblFullName.AutoSize = true;
                lblFullName.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblFullName.Location = new Point(9, 25);
                lblFullName.Name     = "lblFullName";
                lblFullName.Size     = new Size(68, 15);
                lblFullName.Text     = "Full Name: " + _student.getStudentData("first_name") + " " +
                                       _student.getStudentData("middle_name") + " " + _student.getStudentData("last_name");

                Label lblGender = new Label();
                lblGender.AutoSize = true;
                lblGender.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblGender.Location = new Point(9, 45);
                lblGender.Name     = "lblGender";
                lblGender.Size     = new Size(57, 15);
                if (_student.getStudentData("gender") == "M")
                {
                    lblGender.Text = "Gender: Male";
                }
                else
                {
                    lblGender.Text = "Gender: Female";
                }

                Label lblAddress = new Label();
                lblAddress.AutoSize = true;
                lblAddress.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblAddress.Location = new Point(8, 65);
                lblAddress.Name     = "lblGender";
                lblAddress.Size     = new Size(51, 15);
                lblAddress.Text     = "Address: " + _student.getStudentData("address");

                Label lblContactNo = new Label();
                lblContactNo.AutoSize = true;
                lblContactNo.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblContactNo.Location = new Point(9, 85);
                lblContactNo.Name     = "lblContactNo";
                lblContactNo.Size     = new Size(103, 15);
                lblContactNo.Text     = "Contact Number: " + _student.getStudentData("contact");

                Label lblEmailAddress = new Label();
                lblEmailAddress.AutoSize = true;
                lblEmailAddress.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblEmailAddress.Location = new Point(9, 105);
                lblEmailAddress.Name     = "lblEmailAddress";
                lblEmailAddress.Size     = new Size(92, 15);
                lblEmailAddress.Text     = "Email Address: " + _student.getStudentData("email");

                Label lblCourse = new Label();
                lblCourse.AutoSize = true;
                lblCourse.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblCourse.Location = new Point(8, 125);
                lblCourse.Name     = "lblCourse";
                lblCourse.Size     = new Size(38, 15);
                lblCourse.Text     = "Course: " + _student.getStudentData("course");

                Label lblYearAndSection = new Label();
                lblYearAndSection.AutoSize = true;
                lblYearAndSection.Font     = new Font("Roboto Light", 9.75F, FontStyle.Regular, GraphicsUnit.Point, ((byte)(0)));
                lblYearAndSection.Location = new Point(8, 145);
                lblYearAndSection.Name     = "lblYearAndSection";
                lblYearAndSection.Size     = new Size(38, 15);
                lblYearAndSection.Text     = "Year and Section: " + _student.getStudentData("year_and_section");

                Label lblSwitchStatus = new Label();
                lblSwitchStatus.AutoSize = true;
                lblSwitchStatus.Font     = new Font("Roboto", 9F, FontStyle.Bold, GraphicsUnit.Point, ((byte)(0)));
                lblSwitchStatus.Location = new Point(369, 20);
                lblSwitchStatus.Name     = "lblSwitchStatus";
                lblSwitchStatus.Size     = new Size(69, 14);
                lblSwitchStatus.Text     = "Deactivated";

                XUISwitch switchIsActivated = new XUISwitch();
                switchIsActivated.BackColor      = Color.Transparent;
                switchIsActivated.HandleOffColor = Color.FromArgb(((int)(((byte)(230)))), ((int)(((byte)(71)))), ((int)(((byte)(89)))));
                switchIsActivated.HandleOnColor  = Color.FromArgb(((int)(((byte)(25)))), ((int)(((byte)(178)))), ((int)(((byte)(255)))));
                switchIsActivated.Location       = new Point(303, 12);
                switchIsActivated.Name           = "switchIsActivated";
                switchIsActivated.OffColor       = Color.FromArgb(((int)(((byte)(234)))), ((int)(((byte)(129)))), ((int)(((byte)(136)))));
                switchIsActivated.OnColor        = Color.FromArgb(((int)(((byte)(102)))), ((int)(((byte)(204)))), ((int)(((byte)(255)))));
                switchIsActivated.Size           = new Size(60, 28);
                switchIsActivated.SwitchState    = XanderUI.XUISwitch.State.Off;
                switchIsActivated.SwitchStyle    = XanderUI.XUISwitch.Style.Horizontal;
                switchIsActivated.Text           = "xuiSwitch1";
                switchIsActivated.Click         += (s, e) => {
                    Student s1 = new Student();
                    if (switchIsActivated.SwitchState == XUISwitch.State.Off)
                    {
                        s1.studentActivation(studentId, 0);
                        lblSwitchStatus.Text = "Deactivated";
                    }
                    else
                    {
                        s1.studentActivation(studentId, 1);
                        lblSwitchStatus.Text = "Activated";
                    }
                };

                Panel panelStudent = new Panel();
                panelStudent.Controls.Add(lblSwitchStatus);
                panelStudent.Controls.Add(lblStudentIDNo);
                panelStudent.Controls.Add(switchIsActivated);
                panelStudent.Controls.Add(lblCourse);
                panelStudent.Controls.Add(lblYearAndSection);
                panelStudent.Controls.Add(lblAddress);
                panelStudent.Controls.Add(lblEmailAddress);
                panelStudent.Controls.Add(lblContactNo);
                panelStudent.Controls.Add(lblFullName);
                panelStudent.Controls.Add(lblGender);
                panelStudent.Location    = new Point(3, 3);
                panelStudent.Name        = "panelStudent";
                panelStudent.BorderStyle = BorderStyle.FixedSingle;
                panelStudent.Size        = new Size(458, 166);

                th.setLabelColor(lblStudentIDNo);
                th.setLabelColor(lblFullName);
                th.setLabelColor(lblGender);
                th.setLabelColor(lblAddress);
                th.setLabelColor(lblContactNo);
                th.setLabelColor(lblEmailAddress);
                th.setLabelColor(lblCourse);
                th.setLabelColor(lblYearAndSection);
                th.setLabelColor(lblSwitchStatus);

                flowLayoutStudent.Controls.Add(panelStudent);
            }
        }