private void btnSave_Click(object sender, System.EventArgs e)
        {
            if (XtraMessageBox.Show("Are you sure you would like to change the default connection?", "Are you sure?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
            {
                string key = listConnections.SelectedValue.ToString();

                string connString =  HistoricConnectionStrings[key];
                ConnectionString connectionString = new ConnectionString();

                connectionString.Parse(connString);
                connectionString.Name = key;
                connectionString.SaveAsDefault();
                lblPreview.Text = connectionString.ToVisibleString();

                XtraMessageBox.Show("The new default has been set.");
                ConnectionHelper.CurrentConnection = connectionString;
                this.Close();
            }
        }
        private void listConnections_DoubleClick(object sender, System.EventArgs e)
        {
            string key = listConnections.SelectedValue.ToString();
            string connString  = HistoricConnectionStrings[key];
            ConnectionString connectionString = new ConnectionString();
            connectionString.Parse(connString);
            lblPreview.Text = connectionString.ToVisibleString();
            connectionString.Name = key;

            new AdvancedConnectionManager( connectionString, this ).Show(this);
            this.Hide();
        }
 private void listConnections_SelectedIndexChanged(object sender, System.EventArgs e)
 {
     if (listConnections.SelectedItem != null)
     {
         string key = listConnections.SelectedItem.ToString();
         ConnectionString connectionString = new ConnectionString();
         connectionString.Parse( HistoricConnectionStrings[key]);
         lblPreview.Text = connectionString.ToVisibleString();
     }
 }