private void btnOk_Click(object sender, EventArgs e) { try { SelectedCertificate = CertificateHelper.CreateSelfSignedCA(txtCN.Text, (int)numExpiration.Value); } catch (Exception ex) { this.ShowError(ex); this.DialogResult = System.Windows.Forms.DialogResult.None; } }
private void SelectCA(X509Certificate2 ca) { txtCA.Text = CertificateHelper.CertificateName(ca); selectedCA = ca; }