Beispiel #1
0
        private void dataGridClientes_CellClick(object sender, DataGridViewCellEventArgs e)
        {
            String columna_seleccionada = this.dataGridClientes.Columns[e.ColumnIndex].Name;

            if (columna_seleccionada == "Seleccionar")
            {
                Object username = dataGridClientes.Rows[dataGridClientes.CurrentCell.RowIndex].Cells["username"].Value;

                if (username == null)
                {
                    MessageBox.Show("Seleccione un cliente");
                    return;
                }
                GridCupones gridCupones = new GridCupones(username.ToString(), this.registro);
                gridCupones.Show();
                this.Hide();
            }
        }
        private void dataGridClientes_CellClick(object sender, DataGridViewCellEventArgs e)
        {
            String columna_seleccionada = this.dataGridClientes.Columns[e.ColumnIndex].Name;

            if (columna_seleccionada == "Seleccionar")
            {

                Object username = dataGridClientes.Rows[dataGridClientes.CurrentCell.RowIndex].Cells["username"].Value;

                if (username == null)
                {
                    MessageBox.Show("Seleccione un cliente");
                    return;
                }
                GridCupones gridCupones = new GridCupones(username.ToString(), this.registro);
                gridCupones.Show();
                this.Hide();
            }
        }