示例#1
0
        private void _500WithdrawButton(object sender, RoutedEventArgs e)
        {
            //dbcon
            ProcessingMessageBox processingMessageBox = new ProcessingMessageBox();

            processingMessageBox.ShowDialog();
            withdrawAmmount.Clear();
            MessageBoxResult resultRecipt = MessageBox.Show("YOUR TRANSACTION IS COMPLETED! DO YOU WANT A PRINTED RECIPT ?", "ATM", MessageBoxButton.YesNo);

            if (resultRecipt == MessageBoxResult.Yes)
            {
                ProcessingMessageBox processingMessageBox_2 = new ProcessingMessageBox();
                processingMessageBox_2.ShowDialog();

                MessageBoxResult resultAnotherTransaction = MessageBox.Show("WOULD YOU LIKE TO PERFORM ANOTHER TRANSACTION?", "ATM", MessageBoxButton.YesNo);

                if (resultAnotherTransaction == MessageBoxResult.No)
                {
                    SessionMenu sessionMenu = new SessionMenu();
                    NavigationService.Navigate(sessionMenu);
                }
            }
            else if (resultRecipt == MessageBoxResult.No)
            {
                MessageBoxResult resultAnotherTransaction = MessageBox.Show("WOULD YOU LIKE TO PERFORM ANOTHER TRANSACTION?", "ATM", MessageBoxButton.YesNo);

                if (resultAnotherTransaction == MessageBoxResult.No)
                {
                    SessionMenu sessionMenu = new SessionMenu();
                    NavigationService.Navigate(sessionMenu);
                }
            }
        }
示例#2
0
        private void ChangePinButton(object sender, RoutedEventArgs e)
        {
            ChangePin changePin = new ChangePin();
            bool?     result    = changePin.ShowDialog();

            if (result.HasValue && result.Value)
            {
                SessionMenu sessionMenu = new SessionMenu();
                NavigationService.Navigate(sessionMenu);
            }
        }
示例#3
0
        private void okButton_Click(object sender, RoutedEventArgs e)
        {
            if (withdrawAmmount.Text.Trim() != String.Empty)
            {
                //dbcon
                ProcessingMessageBox processingMessageBox = new ProcessingMessageBox();
                processingMessageBox.ShowDialog();
                MessageBoxResult resultRecipt = MessageBox.Show("YOUR TRANSACTION IS COMPLETED! DO YOU WANT A PRINTED RECIPT ?", "ATM", MessageBoxButton.YesNo);

                if (resultRecipt == MessageBoxResult.Yes)
                {
                    ProcessingMessageBox processingMessageBox_2 = new ProcessingMessageBox();
                    processingMessageBox_2.ShowDialog();

                    MessageBoxResult resultAnotherTransaction = MessageBox.Show("WOULD YOU LIKE TO PERFORM ANOTHER TRANSACTION?", "ATM", MessageBoxButton.YesNo);

                    if (resultAnotherTransaction == MessageBoxResult.No)
                    {
                        SessionMenu sessionMenu = new SessionMenu();
                        NavigationService.Navigate(sessionMenu);
                    }
                    else
                    {
                        withdrawAmmount.Clear();
                    }
                }
                else if (resultRecipt == MessageBoxResult.No)
                {
                    MessageBoxResult resultAnotherTransaction = MessageBox.Show("WOULD YOU LIKE TO PERFORM ANOTHER TRANSACTION?", "ATM", MessageBoxButton.YesNo);

                    if (resultAnotherTransaction == MessageBoxResult.No)
                    {
                        SessionMenu sessionMenu = new SessionMenu();
                        NavigationService.Navigate(sessionMenu);
                    }
                    else
                    {
                        withdrawAmmount.Clear();
                    }
                }
            }
            else
            {
                MessageBoxResult messageBoxResult = MessageBox.Show("PLEASE ENTER WITHDRAWAL BEFORE PROCEED!", "Confirmation");
            }
        }
示例#4
0
        private void BackButton(object sender, RoutedEventArgs e)
        {
            MessageBoxResult resultRecipt = MessageBox.Show("DO YOU WANT A PRINTED RECIPT ?", "ATM", MessageBoxButton.YesNo);

            if (resultRecipt == MessageBoxResult.Yes)
            {
                ProcessingMessageBox processingMessageBox = new ProcessingMessageBox();
                processingMessageBox.ShowDialog();

                SessionMenu sessionMenu = new SessionMenu();
                NavigationService.Navigate(sessionMenu);
            }
            else
            {
                SessionMenu sessionMenu = new SessionMenu();
                NavigationService.Navigate(sessionMenu);
            }
        }
示例#5
0
        private void submit_button_Click(object sender, RoutedEventArgs e)
        {
            if (accountNumberText.Text.Trim() == String.Empty)
            {
                MessageBoxResult messageBoxResult = MessageBox.Show("PLEASE ENTER ACCOUNT NUMBER BEFORE PROCEED!", "Confirmation");
                accountNumberText.Text = "";
            }
            else
            {
                LoginPin loginpin = new LoginPin();
                bool?    result   = loginpin.ShowDialog();

                if (result.HasValue && result.Value)
                {
                    SessionMenu sessionMenu = new SessionMenu();
                    NavigationService.Navigate(sessionMenu);
                }
            }
        }
示例#6
0
 private void TransferButton(object sender, RoutedEventArgs e)
 {
     if (transferText.Text.Trim() == String.Empty && amountText.Text.Trim() != String.Empty)
     {
         MessageBoxResult result = MessageBox.Show("PLEASE ENTER ACCOUNT NUMBER BEFORE PROCEED", "Confirmation");
         transferText.Text = "";
         amountText.Text   = "";
     }
     else if (amountText.Text.Trim() == String.Empty && transferText.Text.Trim() != String.Empty)
     {
         MessageBoxResult result = MessageBox.Show("PLEASE ENTER TRANSFER AMOUNT BEFORE PROCEED", "Confirmation");
         transferText.Text = "";
         amountText.Text   = "";
     }
     else if (transferText.Text.Trim() == String.Empty || amountText.Text.Trim() == String.Empty)
     {
         MessageBoxResult result = MessageBox.Show("PLEASE ENTER ACCOUNT NUMBER AND TRANSFER AMOUNT", "Confirmation");
         transferText.Text = "";
         amountText.Text   = "";
     }
     else
     {
         MessageBoxResult result = MessageBox.Show("MONEY TRANSFERED!!   Do you want to   GET A RECIPT?",
                                                   "Confirmation", MessageBoxButton.YesNoCancel);
         if (result == MessageBoxResult.Yes)
         {
             ProcessingMessageBox processingMessageBox = new ProcessingMessageBox();
             processingMessageBox.ShowDialog();
         }
         else if (result == MessageBoxResult.No)
         {
             SessionMenu sessionMenu = new SessionMenu();
             NavigationService.Navigate(sessionMenu);
         }
         else
         {
             transferText.Text = "";
             amountText.Text   = "";
         }
     }
 }
示例#7
0
        private void ExitButton(object sender, RoutedEventArgs e)
        {
            SessionMenu sessionMenu = new SessionMenu();

            NavigationService.Navigate(sessionMenu);
        }