private void buttonBuscar_click(object sender, EventArgs e) { String mail = textBox3.Text.Trim(); String nroDoc = textBox4.Text.Trim(); KeyValuePair <String, Boolean> estado = new KeyValuePair <String, Boolean>(); estado = new KeyValuePair <String, Boolean>("Habilitado", true); String tipoDoc = ""; RepositorioCliente repositorioClientes = new RepositorioCliente(); if (comboBoxTipoDoc.SelectedItem != null) { tipoDoc = (String)comboBoxTipoDoc.SelectedItem; } List <Cliente> clientes = repositorioClientes.getByQuery("", "", tipoDoc, nroDoc, estado, mail); //MEJORA DE PERFORMANCE DEL DGV dataGridView1.RowHeadersWidthSizeMode = DataGridViewRowHeadersWidthSizeMode.EnableResizing; dataGridView1.RowHeadersVisible = false; dataGridView1.DataSource = clientes; dataGridView1.RowHeadersVisible = true; //ESTO LO TENGO QUE HACER PARA QUE NO APAREZCA SIEMPRE SELECCIONADO EL PRIMER ITEM dataGridView1.CurrentCell = null; dataGridView1.ClearSelection(); //ESTO ES PARA QUE ME ACTUALICE LA LISTA DE DOCUMENTOS POSIBLES RepositorioIdentidad repoIdentidad = new RepositorioIdentidad(); comboBoxTipoDoc.DataSource = repoIdentidad.getAllTiposDocsClientes(); comboBoxTipoDoc.SelectedValue = ""; }