<div style='background-color: none transparent;'></div>

Pages

Home » , , » ADVANCE LOGIN FORM FOR SYSTEM SECURITY

ADVANCE LOGIN FORM FOR SYSTEM SECURITY

PROGRAM DESCRIPTION

This program is an advance login security for your system. add this in your project then you have it 100% working. just dont forget to add the database. you may download the full project source code below for free!!!
 
SCREENSHOT  



CODE

Module


Option Explicit

Public conn As ADODB.Connection

Public Sub connect()
Set conn = New ADODB.Connection
    conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\myDatabase.mdb;Persist Security Info=False"
End Sub

Sub main()
connect
frmLogin.Show
End Sub

frmLogin

Private Sub cmdCancel_Click()
End
End Sub

Private Sub cmdOK_Click()

Dim rs As New ADODB.Recordset

rs.Open "SELECT * FROM tblUser WHERE username = '" & txtUserName & "'", conn, adOpenStatic, adLockReadOnly
    If rs.RecordCount <> 0 Then
        If txtPassword = rs!password Then

            MsgBox "Username and Password Succesful!"
            'Remove msgbox above then call a form to be load if login is succesful!
       
        Else
            MsgBox "Invalid Password, try again!", , "Login"
        End If
    Else
        MsgBox "Invalid Login, try again!", , "Login"

    End If
    rs.Close
    Set rs = Nothing

End Sub






Share this article :

No comments :

Post a Comment

 
Copyright © 2011. datasavvy . All Rights Reserved
Company Info | Contact Us | Privacy policy | Term of use | Widget | Advertise with Us | Site map
Template Modify by Creating Website . Inpire by Darkmatter Rockettheme Proudly powered by Blogger