private void fillGrid() { db = new DB(); try { chkSelect.Checked = true; newAccountsTable = db.getNewAccounts(wizard); foreach (DataColumn column in newAccountsTable.Columns) column.ReadOnly = true; newAccountsTable.Columns[DB.IMPORT].ReadOnly = false; dataGridView1.DataSource = newAccountsTable; } catch (Exception ex) { MessageBox.Show(ex.Message); Close(); } }