Exemplo n.º 1
0
 private void Login_Click(object sender, RoutedEventArgs e)
 {
     try
     {
         remember();
         cnt++;
         shopWindows = new ShopWindows(tbLogin.Text, dp.HashPassword(tbPassword.Password));
         shopWindows.Show();
         Close();
     }
     catch (FaultException ex)
     {
         MessageBox.Show(string.Format("{0} - {1}", ex.Code.Name, ex.Message), "ERROR", MessageBoxButton.OK);
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.Message, "ERROR", MessageBoxButton.OK);
     }
     finally
     {
         if (cnt != 0)
         {
             resetpassword.Visibility = Visibility.Visible;
         }
     }
 }
Exemplo n.º 2
0
 public Test()
 {
     InitializeComponent();
     Loaded += Window_Loaded;
     ShopWindows shopWindows = new ShopWindows("admin", dp.HashPassword("admin"));
 }
Exemplo n.º 3
0
 public CallbackClass(ShopWindows shopWindows)
 {
     this.shopWindows = shopWindows;
 }