Upload

Loading...

How To Make A Game On Visual Basic 2008

12,265 views

Loading...

Loading...

Loading...

Rating is available when the video has been rented.
This feature is not available right now. Please try again later.
Uploaded on Nov 11, 2008

Public Class Form1 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim Therandom As New Random If RadioButton1.Checked = True Then Label1.Visible = False Label2.Visible = False Label3.Visible = False Label1.Text = Therandom.Next(1, 5) If TextBox1.Text = Label1.Text Then Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU ARE CORRECT!!" Button1.Enabled = False TextBox1.Enabled = False Else Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU LOSE!!" Button1.Enabled = False TextBox1.Enabled = False End If ElseIf RadioButton2.Checked = True Then Label1.Visible = False Label2.Visible = False Label3.Visible = False Label1.Text = Therandom.Next(1, 15) If TextBox1.Text = Label1.Text Then Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU ARE CORRECT!!" Button1.Enabled = False TextBox1.Enabled = False Else Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU LOSE!!" Button1.Enabled = False TextBox1.Enabled = False End If ElseIf RadioButton3.Checked = True Then Label1.Visible = False Label2.Visible = False Label3.Visible = False Label1.Text = Therandom.Next(1, 50) If TextBox1.Text = Label1.Text Then Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU ARE CORRECT!!" Button1.Enabled = False TextBox1.Enabled = False Else Label1.Visible = True Label2.Visible = True Label3.Visible = True Label3.Text = "YOU LOSE!!" Button1.Enabled = False TextBox1.Enabled = False End If End If End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Label1.Text = "0" Label1.Visible = False Label2.Visible = False Label3.Visible = False Button1.Enabled = True TextBox1.Enabled = True TextBox1.Text = "" End Sub
End Class

Loading...

Advertisement
When autoplay is enabled, a suggested video will automatically play next.

Up next


to add this to Watch Later

Add to

Loading playlists...