Beispiel #1
0
        protected void SubmitClicked(object sender, ImageClickEventArgs e)
        {
            if (Page.IsValid)
            {
                // Get the user info from the text boxes
                string userId   = WebComponents.CleanString.InputText(txtUserId.Text, 50);
                string password = WebComponents.CleanString.InputText(txtPassword.Text, 50);

                // Hand off to the account controller to control the naviagtion
                ProcessFlow.AccountController accountController = new ProcessFlow.AccountController();

                if (!accountController.ProcessLogin(userId, password))
                {
                    // If we fail to login let the user know
                    valUserId.ErrorMessage = MSG_FAILURE;
                    valUserId.IsValid      = false;
                }
            }
        }