Password Validation

Swapnil Salunke replied to Timothy Purvis at 04-Jul-08 12:15
HEllO Timothy Purvis

this is your code only I have modified hope this will work
theres no need to give two queries

Call ConnectRS(CN, RS, "SELECT name,password FROM staff where name ='" & txtName.Text & "'")
If RS.RecordCount = 0 Then  ' Means here the Username is incorrect
        MsgBox "Invalid Name entered", vbCritical
        txtName.Text = ""
        CN.Close
        Call ConnectDB(CN, App.Path & "\users.mdb")
        Exit Sub
else                                       ' Means here the UserName is correct check for the PWD 
      if (txtpassword.text = rs!password)
      {
            'User Autenticated 
      }
      else
      {
        ' Passowrd Wrong
      }
End If
RS.Close

Hope this will help you
Happy Coding takecare Bye



Click here to sign in and reply. You could earn money via our $500 contest just for being helpful.
  Password Validation - Timothy Purvis  03-Jul-08 09:18 9:18:00 PM
      Try this - sri sri  03-Jul-08 11:25 11:25:41 PM
      Password Validation - Swapnil Salunke  04-Jul-08 12:15 12:15:54 AM
          parssword vali - Umapathy Kaliaperumal  04-Jul-08 12:26 12:26:49 AM
              Its not advisable to use both validation at once - Arjun Priyananth  04-Jul-08 12:52 12:52:19 AM
      Filter - sundar k  04-Jul-08 04:21 4:21:25 AM
      Password Validation - Sanjay Verma  04-Jul-08 05:21 5:21:59 AM
View Posts

promotion
Silverlight    WPF    WCF    WWF    LINQ   
JavaScript    AJAX    ASP.NET    XAML   
C#    VB.NET    VB 6.0    GDI+    IIS    XML   
.NET Generics    Anonymous Methods    Delegate   
Visual Studio .NET    Expression Blend    Virus   
Windows Vista    Windows XP    Windows Update   
Windows 2003 Server    Windows 2008 Server   
SQL Server    Microsoft Excel    Microsoft Word   
SharePoint    BizTalk    Virtual Earth   
.NET Compact Framework    Web Service   


"Everything" RSS / ATOM Feed Parser
How to send and receive messages through message queuing in .Net
How to Read text file as database
SQL Server 2005 Paging Performance Tip
Display code of web page.
Fully Scalable Excel File Importer class for .net using Microsoft Jet driver
Generic Chart Color Manager class that can be used for any charts
Helper class to style the infragistics wingrid
Using Reflection to detemine as Assembly Info in and out.
Helper class to play with Window (Owners and position)
Resolving displayname from the culture using the XmlLanguage and LanguageSpecificStringDictionary class