Example #1
0
        private void buttonRegister_Click(object sender, RoutedEventArgs e)
        {
            try
            {
                if (this.Connect() == false)
                {
                    throw new ConnectingException();
                }

                var windowCreateAccount = new WindowCreateAccount();
                windowCreateAccount.Owner = this;
                windowCreateAccount.Show();
            }

            catch (ConnectingException)
            {
            }

            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error!");
            }
        }
Example #2
0
        private void buttonRegister_Click(object sender, RoutedEventArgs e)
        {
            try
            {
                if (this.Connect() == false)
                {
                    throw new ConnectingException();
                }

                var windowCreateAccount = new WindowCreateAccount();
                windowCreateAccount.Owner = this;
                windowCreateAccount.Show();
            }

            catch (ConnectingException)
            {
            }

            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Error!");
            }
        }