Esempio n. 1
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            AccessToken myAccessToken = default(AccessToken);

            frmStartUp myForm = default(frmStartUp);

            try
            {
                myAccessToken = Authenticator.Authenticate(int.Parse(txtUserID.Text), txtPassword.Text);

                myForm = new frmStartUp(myAccessToken);
                myForm.Show();
                Hide();
            }
            catch (Exception)
            {
                MessageBox.Show("Please contact your administrator or try again.", "Error!");
            }
        }
Esempio n. 2
0
        private void btnLogin_Click(object sender, EventArgs e)
        {
            AccessToken myAccessToken = default(AccessToken);

               frmStartUp myForm = default(frmStartUp);
            try
            {

                myAccessToken = Authenticator.Authenticate(int.Parse(txtUserID.Text), txtPassword.Text);

                myForm = new frmStartUp(myAccessToken);
                myForm.Show();
                Hide();

            }
            catch (Exception)
            {
                MessageBox.Show("Please contact your administrator or try again.", "Error!");
            }
        }