Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Private Sub btn1_Click(sender As Object, e As EventArgs) Handles btn1.Click
- If cb1.SelectedIndex = 0 Then
- tb3.Text = Int(tb1.Text) + Int(tb2.Text)
- End If
- If cb1.SelectedIndex = 1 Then
- tb3.Text = Int(tb1.Text) - Int(tb2.Text)
- End If
- If cb1.SelectedIndex = 2 Then
- tb3.Text = Int(tb1.Text) / Int(tb2.Text)
- End If
- If cb1.SelectedIndex = 3 Then
- tb3.Text = Int(tb1.Text) * Int(tb2.Text)
- End If
- If cb1.SelectedIndex = 4 Then
- End If
- If cb1.SelectedIndex = 5 Then
- If tb1.Text = "" Then
- tb3.Text = Math.Sin(tb2.Text)
- End If
- Else
- tb3.Text = Math.Sin(tb2.Text) * Int(tb1.Text)
- End If
- If cb1.SelectedIndex = 6 Then
- If tb1.Text = "" Then
- tb3.Text = Math.Cos(tb2.Text)
- End If
- Else
- tb3.Text = Math.Cos(tb2.Text) * Int(tb1.Text)
- End If
- If cb1.SelectedIndex = 7 Then
- If tb1.Text = "" Then
- tb3.Text = Math.Tan(tb2.Text)
- End If
- Else
- tb3.Text = Math.Tan(tb2.Text) * Int(tb1.Text)
- End If
- End Sub
- End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement