Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 'Jack McGrath'
- '12/12/13'
- Public Class Form1
- 'Form Load
- Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
- txtarea.Visible = False
- txtcirc.Visible = False
- lblarea.Visible = False
- lblcirc.Visible = False
- End Sub
- Private Sub btnarea_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnarea.Click
- txtarea.Visible = True
- lblarea.Visible = True
- btncirc.Visible = False
- End Sub
- Private Sub btncirc_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btncirc.Click
- txtcirc.Visible = True
- lblcirc.Visible = True
- btnarea.Visible = False
- End Sub
- 'Area Answer'
- Private Sub txtarea_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtarea.TextChanged
- Dim intarea As Integer
- intarea = txtarea.Text
- lblarea.Text = intarea ^ 2 * 3.14159265359
- intarea = 3.14159265359
- End Sub
- 'Circumference Answer'
- Private Sub txtcirc_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles txtcirc.TextChanged
- Dim intcirc As Integer
- intcirc = txtcirc.Text
- lblcirc.Text = intcirc * 2 * 3.14159265359
- intcirc = 3.14159265359
- End Sub
- End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement