private void txtPedido_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F2) { e.Handled = true; fShow fsw = new fShow("PEDIDO", new string[] { "ID", "CLIENTE_ID", "DATA", "TOTALBRUTO", "TOTALLIQUIDO" }, "DATA"); fsw.ShowDialog(); if (!string.IsNullOrEmpty(fsw.ParametroID.ToString())) { txtPedido.Text = fsw.ParametroID.ToString(); SendKeys.SendWait("{ENTER}"); } } }
private void txtFormaPagamento_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F2) { e.Handled = true; fShow fsw = new fShow("FormasPagamento", new string[] { "Id", "Descricao" }, "Descricao"); fsw.ShowDialog(); txtFormaPagamento.Text = int.Parse(fsw.ParametroID.ToString()).ToString(); if (!string.IsNullOrEmpty(txtFormaPagamento.Text)) { SendKeys.SendWait("{ENTER}"); } } }
private void txtEntrega_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F2) { e.Handled = true; fShow fsw = new fShow("TRANSPORTADORES", new string[] { "ID", "DESCRICAO", "TAXA" }, "DESCRICAO"); fsw.ShowDialog(); if (!string.IsNullOrEmpty(fsw.ParametroID.ToString())) { txtEntrega.Text = int.Parse(fsw.ParametroID.ToString()).ToString(); SendKeys.SendWait("{ENTER}"); } } }
private void txtVendedor_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F2) { fShow fsw = new fShow("Vendedores", new string[] { "Id", "Nome", "CPF", "Endereco", "Cidade", "Estado", "Telefone" }, "nome"); fsw.ShowDialog(); txtVendedor.Text = fsw.ParametroID.ToString(); if (!string.IsNullOrEmpty(txtVendedor.Text)) { SendKeys.SendWait("{ENTER}"); } } }
private void txtEditor_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.F2) { e.Handled = true; fShow fsw = new fShow("PRODUTOS", new string[] { "ID", "DESCRICAO", "CODEBAR", "ESTOQUE_ATUAL", "PRECO_VENDA" }, "DESCRICAO"); fsw.ShowDialog(); txtEditor.Text = int.Parse(fsw.ParametroID.ToString()).ToString(); if (!string.IsNullOrEmpty(txtEditor.Text)) { SendKeys.SendWait("{ENTER}"); txtEditor.Visible = false; GrdPro.Focus(); } } }