Private Sub Command1_Click()
Dim X As String
X = "select * from Table_Login Where Username='" & Text1.Text & "' And Password='" & Text2.Text & "'"
Set Rs = New ADODB.Recordset
Set Rs = Conn.Execute(X)
If Not Rs.EOF Then
MsgBox "Selamat Datang Di Program Sederhana Ini", vbInformation, "Http://pusatanime13.blogspot.com"
Exit Sub
End If
If Text1.Text = "" Then
MsgBox "Anda Belum Mengisi Username", vbExclamation, "Http://pusatanime13.blogspot.com"
Text1.SetFocus
Exit Sub
End If
If Text2.Text = "" Then
MsgBox "Anda Belum Mengisi Password", vbExclamation, "Http://pusatanime13.blogspot.com"
Text2.SetFocus
Else
MsgBox "Username Sama Password Salah Coy", vbCritical, "Http://pusatanime13.blogspot.com"
Text1.SelStart = 0
Text1.SelLength = Len(Text1.Text)
Text1.SetFocus
Exit Sub
End If
End Sub
Private Sub Form_Activate()
Call Connect
End Sub
Private Sub Form_Unload(Cancel As Integer)
End
End Sub
Private Sub Image1_Click()
PopupMenu Form2.about, 8, 800
End Sub