View Single Post
  #2 (permalink)  
Old May 22nd, 2006, 10:24 AM
mmcdonal mmcdonal is offline
Friend of Wrox
Points: 9,611, Level: 42
Points: 9,611, Level: 42 Points: 9,611, Level: 42 Points: 9,611, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Mar 2004
Location: Washington, DC, USA.
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

Which line is giving you the error?

I see you might want to remove the ";" at the end of the SQL statement if it is an Access back end.

Also, you might want to limit the SQL statement to:

"SELECT * FROM Users WHERE [UserName] = " & "'" & sUserNameVariable & "'"

This will give you a recordset with 1 record, which is easier to work with. Start with:

If rs.RecordCount = 0 Then
   Exit Sub
End If



mmcdonal