예제 #1
0
        private void btnSumar_Click(object sender, EventArgs e)
        {
            Suma    sum    = new Suma();
            clsSuma clsSum = new clsSuma();

            sum.Dato1 = Convert.ToDouble(value: txtD1.Text);
            sum.Dato2 = Convert.ToDouble(value: txtD2.Text);
            Double Res = clsSum.suma(sum);

            txtRes.Text = Res.ToString();
        }
예제 #2
0
        private void btnAcc_Click(object sender, EventArgs e)
        {
            frmSuma frms     = new frmSuma();
            Suma    sumar    = new Suma();
            clsSuma clsSumar = new clsSuma();

            sumar.User = txtUser.Text;
            sumar.Pass = txtContra.Text;
            Boolean correc = clsSumar.entrar(sumar);

            if (correc == true)
            {
                MessageBox.Show("WELCOME");
                frms.Show();
            }
            else
            {
                MessageBox.Show("Stop");
            }
        }