internal async Task ModificarAsync(GastoListadoItem gastoListadoItem) { GastoDetalleForm gastoDetalleForm = new GastoDetalleForm(gastoListadoItem.Gasto); gastoDetalleForm.ShowDialog(); await BuscarAsync(); }
private void dgGastos_CellMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e) { EjecutarAsync(async() => { if (e.RowIndex < 0) { return; } GastoListadoItem gastoListadoItem = (GastoListadoItem)dgGastos.CurrentRow.DataBoundItem; await gastoListadoViewModel.ModificarAsync(gastoListadoItem); }); }
private void dgGastos_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e) { EjecutarAsync(async() => { if (e.RowIndex < 0) { return; } GastoListadoItem gastoListadoItem = (GastoListadoItem)dgGastos.CurrentRow.DataBoundItem; if (dgGastos.Columns[e.ColumnIndex].Name == "Editar") { await gastoListadoViewModel.ModificarAsync(gastoListadoItem); } }); }