data member not found

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • meetmaruthi
    New Member
    • Apr 2006
    • 1

    data member not found

    Hai i am searching a database (in ms access ) to validate user info.it has two fields username and password.
    here is the coding and i get compile error:Method or data member not found.please help
    Private Sub Command1_Click( )
    Set ch = ADODB.Recordset
    Adodc1.Connecti onString = "Provider=Micro soft.Jet.OLEDB. 4.0;Data Source=C:\Progr am Files\Microsoft Visual Studio\sruniep\ ssp\db\user.mdb ;Mode=ReadWrite |Share Deny None;Persist Security Info=False"
    ssql = "SELECT * FROM log WHERE Username =" & Text1.Text & " AND Password = " & Text2.Text & " "
    ch.open ssql, Conn, adOpenDynamic, adLockReadOnly

    If Not ch.EOF Then
    main.Show
    Unload Me ' Unload login form
    Else
    MsgBox " Invalid Login!! Username and Password did not match", vbCritical
    i = i + 1 'Another chance passes by
    End If
    If i = 3 Then 'Not a member
    Unload Me
    MsgBox "Aborting Application :Restart Application with proper Authentication" , vbCritical
    Unload main
    End If
    ch.Close 'Close the recordset
    Set ch = Nothing
    End Sub


    when i run the program it highlights the folowing line in yellow
    Set ch = ADODB.Recordset
    and reports Comple Error:Method or Data Member not found

    i am accessing login info stored in an ms access database "database is user.mdb and table is log"
    please guys help me in this matter
    mai me at<meetmaruthi@ gmail.com>
Working...