Membuat Form Login di VB.Net
S1. Siapkan Label 3, Textbox 2, Form2, dan Button 1.
22. Set propertiesnya sebagai berikut :
Label1
| |
Text
|
Login
|
Label2
| |
Text
|
Username
|
Label3
| |
Text
|
Password
|
Textbox2
| |
Pswdchar
|
*
|
Button1
| |
Text
|
Log in
|
33. Masukan kode berikut :
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If TextBox1.Text = "admin" And TextBox2.Text = "admin" Then
MsgBox("Login Berhasil", MsgBoxStyle.DefaultButton1 + MsgBoxStyle.Information, "Login Sukses")
Form2.Show()
Else
MsgBox("Login Gagal !!", MsgBoxStyle.Critical + MsgBoxStyle.DefaultButton3, "Error")
End If
End Sub
End Class
4. Untuk yang berwarna merah, kalian bisa merubahnya.
4. Dan Start Debugging atau tekan tombol F5
5. Masukan Username : admin dan Password : admin
Membuat Form Login di VB.Net
Reviewed by Noval Ramadhan
on
19:58
Rating:
Reviewed by Noval Ramadhan
on
19:58
Rating:


No comments: