public FMesclaDAV() { // Required for Windows Form Designer support InitializeComponent(); ListaDavCabecalho = new List <DavCabecalhoVO>(); ListaDavDetalhe = new List <DavDetalheVO>(); DAVController = new DAVController(); GridMestre.AutoGenerateColumns = false; GridDetalhe.AutoGenerateColumns = false; CarregarCabecalho(); GridMestre.Focus(); }
public FCancelaPreVenda() { // Required for Windows Form Designer support InitializeComponent(); ListaPreVendaCabecalho = new List <PreVendaCabecalhoVO>(); ListaPreVendaDetalhe = new List <PreVendaDetalheVO>(); PreVendaController = new PreVendaController(); GridMestre.AutoGenerateColumns = false; GridDetalhe.AutoGenerateColumns = false; CarregarCabecalho(); GridMestre.Focus(); }
public void GridMestreKeyDown(object sender, KeyEventArgs e) { try { if (e.KeyCode == Keys.Space) { if (ListaDavCabecalho[GridMestre.CurrentRow.Index].Situacao == null) { ListaDavCabecalho[GridMestre.CurrentRow.Index].Situacao = "X"; } else { ListaDavCabecalho[GridMestre.CurrentRow.Index].Situacao = null; } } GridMestre.DataSource = ListaDavCabecalho; GridMestre.Refresh(); } catch (Exception eError) { Log.write(eError.ToString()); } }