예제 #1
0
        private void LoginCheck()
        {
            LoginWin login = new LoginWin();

            login.Owner = this;

            bool?result = login.ShowDialog();

            if (result == true)
            {
                frame_content.Navigate(new Uri("view/Pages/Home.xaml", UriKind.Relative));

                if (login.CheckBox.IsChecked == (bool?)true)
                {
                    loginVM.SetBool(true);
                }
            }
        }
예제 #2
0
 public bool Login(LoginInfo logininfo)
 {
     if (winshow == true)
     {
         return(false);
     }
     try
     {
         winshow      = true;
         loginSucceed = false;
         logininfo.RrrorInformation = "";//清空信息
         loginWin              = new LoginWin(logininfo);
         loginWin.Title        = (string)Application.Current.Resources["strLogin"];
         loginWin.Parachanged += Win_Parachanged;
         loginWin.ShowDialog();
         return(loginSucceed);
     }
     finally
     {
         winshow = false;
     }
 }