private void button1_Click(object sender, EventArgs e) { //refresh list TestServiceClient client = new TestServiceClient(); string[][] rows; try { client.Open(); rows = client.GetAllContacts(); client.Close(); } catch (Exception ex) { MessageBox.Show(ex.ToString()); return; } dataGridView1.Rows.Clear(); for (int i=0;i<rows.Length;i++) { dataGridView1.Rows.Add(rows[i][0], rows[i][1]); } foreach (Control c in Controls) c.Enabled = true; }