Ejemplo n.º 1
0
        protected void Button2_Click(object sender, EventArgs e)
        {
            Kalkulator k = new Kalkulator();

            int wynik = k.odejmowanie(Int32.Parse(TextBox1.Text),
                                      Int32.Parse(TextBox2.Text));

            Label2.Text = "" + wynik;
        }
Ejemplo n.º 2
0
        protected void Button4_Click(object sender, EventArgs e)
        {
            Kalkulator k = new Kalkulator();

            float wynik = k.dzielenie(Int32.Parse(TextBox1.Text),
                                      Int32.Parse(TextBox2.Text));

            Label2.Text = "" + wynik;
        }
Ejemplo n.º 3
0
        protected void Button5_Click(object sender, EventArgs e) // Potega
        {
            Kalkulator k = new Kalkulator();

            int wynik;

            Label6.Text = "1";

            for (int i = 0; i < Int32.Parse(TextBox4.Text); i++)
            {
                wynik = k.mnozenie(Int32.Parse(TextBox3.Text),
                                   Int32.Parse(Label6.Text));


                Label6.Text = "" + wynik;
            }
        }