コード例 #1
0
        private void buttonLogin_Click(object sender, EventArgs e)
        {
            Login job = new Login();

            job.Username = textUserName.Text;
            job.Password = textPassword.Text;

            List <CandidateEmployee> AllCandidate = candidatedbhelper.GetAllCandidates();
            int count = 0;

            foreach (CandidateEmployee item in AllCandidate)
            {
                if (item.Email == job.Username && item.Epassword == job.Password)
                {
                    LoginID = item.ECandidateID;
                    count   = 1;
                    this.Hide();
                    CandidatePanal jobopen = new CandidatePanal();
                    jobopen.Show();
                }
            }
            if (count != 1)
            {
                MessageBox.Show("invalid login");
                CandidateLogin cd = new CandidateLogin();
                this.Hide();
                cd.Show();
            }
        }
コード例 #2
0
        private void Add_Click(object sender, EventArgs e)
        {
            CandidateEmployee obj = new CandidateEmployee();

            obj.EName     = textEName.Text;
            obj.Email     = textEmail.Text;
            obj.Epassword = textEpassword.Text;

            obj.ConfirmPassword  = textConfirmPassword.Text;
            obj.MobileNumber     = textMobileNumber.Text;
            obj.EducationalLevel = textEducationalLevel.Text;
            obj.ExperienceYears  = int.Parse(textExperienceYears.Text);
            obj.CVPath           = textCVPath.Text;
            obj.CoverLetterPath  = textCoverLetterPath.Text;

            if (textEpassword.Text == textConfirmPassword.Text)
            {
                int result = candidatedbhelper.AddCandidate(obj);
                if (result > 0)
                {
                    MessageBox.Show("Registration Sucessfull");
                    this.Hide();
                    CandidateLogin jobopen = new CandidateLogin();
                    jobopen.ShowDialog();
                }
            }
            else
            {
                validations.Text = "* password and conform password do not match";
                textEName.Text   = obj.EName;
            }
        }
コード例 #3
0
        private void button1_Click(object sender, EventArgs e)
        {
            this.Hide();
            CandidateLogin id = new CandidateLogin();

            id.Show();
        }
コード例 #4
0
        private void buttonBackToHome_Click(object sender, EventArgs e)
        {
            this.Hide();
            CandidateLogin jobopen = new CandidateLogin();

            jobopen.ShowDialog();
        }