You are on page 1of 1

ADD

2-BUTTONS
1-TIMER
1-PROGRESSBAR
2-LABELS
2-TEXTBOXES

rename
BUTTON1-LOGIN
BUTTON2-EXIT
LABEL1-USERNAME:
LABEL2-PASSWORD:

Login form + linking form


add this code

Public Class Form1

Private Sub Button2_Click(sender As Object, e As EventArgs) Handles


Button2.Click
Close()
End Sub

Private Sub Button1_Click(sender As Object, e As EventArgs) Handles


Button1.Click
If TextBox1.Text = "anonymous" And TextBox2.Text = "09358108794" Then
Timer1.Start()
Else
MsgBox("Username or Password is Incorrect", MsgBoxStyle.Critical,
"Error")
End If
End Sub

Private Sub Timer1_Tick(sender As Object, e As EventArgs) Handles Timer1.Tick


ProgressBar1.Increment(3)
Label3.Text = ProgressBar1.Value
If ProgressBar1.Value = ProgressBar1.Maximum Then
form2.show()
Me.Hide()
End If
End Sub
End Class

You might also like