Example #1
0
 private void txtBinIn_Leave(object sender, EventArgs e)
 {
     if (!NumeroBinario.Validar(txtBinIn.Text))
     {
         txtBinIn.Focus();
     }
 }
Example #2
0
 private void button1_Click(object sender, EventArgs e)
 {
     if (NumeroBinario.Validar(txtBinIn.Text))
     {
         txtDecOut.Text = Conversor.BinarioDecimal(txtBinIn.Text).ToString();
     }
     else
     {
         txtBinIn.Focus();
     }
 }