Esempio n. 1
0
        private void btnCreate_Click(object sender, System.EventArgs e)
        {
            if (!txtServerPassword.Text.Equals(txtServerPasswordConfirm.Text))
            {
                MessageBox.Show(this, "The server passwords don't match.");
                return;
            }
            if (!txtClientPassword.Text.Equals(txtClientPasswordConfirm.Text))
            {
                MessageBox.Show(this, "The client passwords don't match.");
                return;
            }
            if (folderBrowserDialog1.ShowDialog(this) == DialogResult.OK)
            {
                keystoreFolder = folderBrowserDialog1.SelectedPath;
            }
            else
            {
                return;
            }

            btnCreate.Enabled = false;
            pleaseWaitForm    = new PleaseWaitForm();
            pleaseWaitForm.Show();
            Thread thread = new Thread(new ThreadStart(createRSAKeys));

            thread.Start();
        }
Esempio n. 2
0
 private void OnKeyCreationComplete(object sender, EventArgs e)
 {
     if (pleaseWaitForm != null)
     {
         pleaseWaitForm.Hide();
         pleaseWaitForm.Close();
         pleaseWaitForm = null;
     }
     btnCreate.Enabled = true;
 }