Exemplo n.º 1
0
 private void PrecioNumericUpDown_ValueChanged(object sender, EventArgs e)
 {
     if (CostoNumericUpDown.Value != 0)
     {
         GananciasNumericUpDown.Value = CalculosBLL.CalcularGanancias(PrecioNumericUpDown.Value, CostoNumericUpDown.Value);
     }
 }
Exemplo n.º 2
0
        protected void PrecioTextBox_TextChanged(object sender, EventArgs e)
        {
            if (CostoTextBox.Text != "" && PrecioTextBox.Text != "")
            {
                var ganacias = CalculosBLL.CalcularGanancias(Utils.ToDecimal(PrecioTextBox.Text), Utils.ToDecimal(CostoTextBox.Text));

                GanaciasTextBox.Text = ganacias.ToString();
            }

            else
            {
                GanaciasTextBox.Text = "";
            }
        }