Exemplo n.º 1
0
 private void txtVH_KeyPress(object sender, KeyPressEventArgs e)
 {
     if (e.KeyChar == ',')
     {
         e.KeyChar = Testes.soumaVirgula(txtVH.Text);
     }
     e.KeyChar = Testes.consistNum(e.KeyChar);
 }
Exemplo n.º 2
0
 private void txtHT_KeyPress(object sender, KeyPressEventArgs e)
 {
     if (txtNome.Text.Trim() == "")
     {
         MessageBox.Show("Preencha o nome do funcionário.");
         txtNome.Focus();
     }
     if (e.KeyChar == ',')
     {
         e.KeyChar = Testes.soumaVirgula(txtHT.Text);
     }
     e.KeyChar = Testes.consistNum(e.KeyChar);
 }
Exemplo n.º 3
0
 private void txtNome_KeyPress(object sender, KeyPressEventArgs e)
 {
     e.KeyChar = Testes.consistLet(e.KeyChar);
 }