private void Button_Click(object sender, RoutedEventArgs e)
        {
            if (MessageBox.Show("", "", MessageBoxButton.YesNo, MessageBoxImage.Warning) == MessageBoxResult.Yes)
            {
                SqlConnection con = null;
                try
                {
                    con = new SqlConnection(wizard.settings.SqlConString);
                }
                catch (Exception ex)
                {
                    MessageBox.Show(ex.Message);
                    return;
                }

                LoadingPage loadingPage = new LoadingPage(true, false);
                loadingPage.Title = "instaling Sql TablesPage";
                loadingPage.backgroundWorker.DoWork             += backgroundWorker_DoWork;
                loadingPage.backgroundWorker.RunWorkerCompleted += backgroundWorker_RunWorkerCompleted;

                wizard.frame.Navigate(loadingPage);

                loadingPage.backgroundWorker.RunWorkerAsync(con);
            }
        }
Ejemplo n.º 2
0
        void butten_Click(object sender, RoutedEventArgs e)
        {
            SqlConnection con = null;

            try
            {
                con = new SqlConnection(wizard.settings.SqlConString);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
                return;
            }

            LoadingPage loadingPage = new LoadingPage(true, true);

            loadingPage.Title = "Testig SQL connection string";
            loadingPage.backgroundWorker.DoWork             += backgroundWorker_DoWork;
            loadingPage.backgroundWorker.RunWorkerCompleted += backgroundWorker_RunWorkerCompleted;
            loadingPage.cancelButton.Click += cancelButton_Click;

            wizard.frame.Navigate(loadingPage);
            loadingPage.backgroundWorker.RunWorkerAsync(con);
        }
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            if (MessageBox.Show("", "", MessageBoxButton.YesNo, MessageBoxImage.Warning) == MessageBoxResult.Yes)
            {
                SqlConnection con = null;
                try
                {
                    con = new SqlConnection(wizard.settings.SqlConString);
                }
                catch (Exception ex)
                {
                    MessageBox.Show(ex.Message);
                    return;
                }

                LoadingPage loadingPage = new LoadingPage(true, false);
                loadingPage.Title = "instaling Sql TablesPage";
                loadingPage.backgroundWorker.DoWork += backgroundWorker_DoWork;
                loadingPage.backgroundWorker.RunWorkerCompleted += backgroundWorker_RunWorkerCompleted;

                wizard.frame.Navigate(loadingPage);

                loadingPage.backgroundWorker.RunWorkerAsync(con);
            }
        }
Ejemplo n.º 4
0
        void butten_Click(object sender, RoutedEventArgs e)
        {
            SqlConnection con = null;
            try
            {
                con = new SqlConnection(wizard.settings.SqlConString);
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message);
                return;
            }

            LoadingPage loadingPage = new LoadingPage(true, true);
            loadingPage.Title = "Testig SQL connection string";
            loadingPage.backgroundWorker.DoWork += backgroundWorker_DoWork;
            loadingPage.backgroundWorker.RunWorkerCompleted += backgroundWorker_RunWorkerCompleted;
            loadingPage.cancelButton.Click += cancelButton_Click;

            wizard.frame.Navigate(loadingPage);
            loadingPage.backgroundWorker.RunWorkerAsync(con);
        }